python 2.7 runtime_error??

Revision en1, by maximus12793, 2016-10-16 11:01:51

http://codeforces.me/contest/378/submission/21474186

I have submitted the analogous code in c++ and it worked fine. Is there some reason why this does not work even having set the recursion limit to 20k? I have every time the time and memory is well within limit when it crashes. any ideas?

Tags python 2, runtime error, speed

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English maximus12793 2016-10-16 11:01:51 320 Initial revision (published)