Day of the Week by uru

var y,m,d:comp;begin
repeat
read(y,m,d);y:=y-ord(m<3);writeln((y+y div 4-y div 100+y div 400+(26*m+312*ord(m<3)+16)div 10+d)mod 7)until 1=0end.

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

download

return to the top page