Day of the Week by kurimura

import std.stdio;void
main(){for(int
y,m,q;~scanf("%d%d%d",&y,&m,&q);writeln((y+y/4+~(y/100)*3/4+m*13/5+q)%7))m+=m<3?y--,18:6;}

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

download

return to the top page