Day of the Week by nn

for(;[y,m,d]=readline().split(' '),y;print(('#034025036146'[m]-y%400%7+y%100*4-y%4*2+d)%7))d-=y--%4&&m>2

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page