Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
呵呵,不是这段错了,看了您不要FT死过去,如下In Reply To:刚才看到这一段又觉得十分可疑,一做数据果然出问题 Posted by:frkstyc at 2005-06-04 13:46:16 while ((ok(y))and(n>=366))or((not(ok(y)))and(n>=365)) do begin inc(y); if ok(y) then begin w:=(366 mod 7+w) mod 7; if w=0 then w:=7; dec(n,366); end else begin w:=(365 mod 7+w) mod 7; if w=0 then w:=7; dec(n,365); end; end; 改成 while ((ok(y))and(n>=366))or((not(ok(y)))and(n>=365)) do begin if ok(y) then begin w:=(366 mod 7+w) mod 7; if w=0 then w:=7; dec(n,366); end else begin w:=(365 mod 7+w) mod 7; if w=0 then w:=7; dec(n,365); end; inc(y); end; 把inc(y)放在end前面,而不是放在begin后面……我先FT死了…… Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator