ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1000. A+B Problem

1000
Posted by xMagGTU Дмитрий Тишкин GPRS 31 Mar 2006 06:35
why Tle?

var a,b:shortint;
begin
readln(a,b);
if a>0 do for a:=a downto 1 do inc(b)
else for a:=a to -1 do dec(b);
writeln(b);
end.

Please help me ! I can't get sleep until accepted code like one.
Re: 1000
Posted by KAV 31 Mar 2006 09:33
How about a=0? ;)