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 1438. Time Limit Exceeded

ChenXiangRu OLE #4 I think I need help~~ [3] // Problem 1438. Time Limit Exceeded 20 Jul 2006 19:28
any hint please ?
I was also stunned by this test, now I have AC.

i = 0
j = 0
loop1:
   loop2:
      j = j + 1
   if j < i goto loop2
   j = 0
   i = i + 1
if i < 100 goto loop1
(Consecutive labels)

Good luck.

Edited by author 12.08.2006 12:28
Tipikin Evgeniy (USU) Re: OLE #4 I think I need help~~ // Problem 1438. Time Limit Exceeded 12 Aug 2006 12:18
I think that your program incorrectly interprets input program. For example, there are cycle in which there are print operation and your program incorrectly works with this cycle. Maybe your program enters in infinite cycle in that case. (The cycle is 'label' and 'goto label') I advise you examine work with labels.
AterLux Re: OLE #4 I think I need help~~ // Problem 1438. Time Limit Exceeded 11 Sep 2010 05:51
check for backward and forward links

x = 1
goto lab
x = 10
lab:
x = x + 1
if x < 3 goto lab
print x