how to find day of week from date code example
Example 1: day to week
var d = 1 // Amount of days
console.log(d/7) // Logs amount of weeks
Example 2: get day from date algo
dow(m,d,y){y-=m<3;return(y+y/4-y/100+y/400+"-bed=pen+mad."[m]+d)%7;}
var d = 1 // Amount of days
console.log(d/7) // Logs amount of weeks
dow(m,d,y){y-=m<3;return(y+y/4-y/100+y/400+"-bed=pen+mad."[m]+d)%7;}