const day= new Date().getDay() //return 0 to 6 let weekday= ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'] console.log(weekday[day])