function epiWeekOfDate(y, m, d) {
const ds = [31,((y%4==0)&&((y%100!=0)||(y%400==0))?29:28),31,30,31,30,31,31,30,31,30,31];
for(let i=m-1; i>=1; i--) {
d+=ds[i-1];
}
let result = Math.floor((d - epiWeekFirstDay(y,1)[2])/7)+1;
if(result === 0) {
return epiWeekOfDate(y-1,12,31);
}
return [y,result];
}