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 1352. Mersenne Primes

Check this sequence, PLEASE!
Posted by Alex Stoff 16 Sep 2005 15:56

2,3,5,7,13,17,19,31,61,89,107,127,521,607,                 1279,2203,2281,3217,4253,4423,9689,9941,                   11213,19937,21701,23209,44497,86243,
110503,132049,216091,756839,859433,
1257787,1398269,2976221,3021377,6972593,
13466917,20996011;

Is it all right? Cuz I got WA...
Help me.
Re: Check this sequence, PLEASE!
Posted by xj.ammo 18 Sep 2005 21:18
Yes the sequence is correct. I don't know what is wrong. There must be a problem with your code
Here is my code
Posted by Alex Stoff 18 Sep 2005 22:14

Const ... {sequence}

Var n:array[1..40] of byte;
    t,i:byte;
Begin
  Readln(t);
  For i:=1 to t do Readln(n[i]);
  For i:=1 to t do Writeln(a[n[i]]);
END.
You know, I have TLE
Posted by Alex Stoff 18 Sep 2005 22:18

I cann't believe it! I Have TLE#4!
Re: You know, I have TLE
Posted by Anatoliy 'Tolyan_NO' Tolstobroff 18 Sep 2005 23:53

You hands is normal? :)
What do you mean "hands".
Posted by Alex Stoff 19 Sep 2005 00:34
I'm asking for help. What do you mean "hands".
Try printing the output as soon as you read it
Posted by xj.ammo 19 Sep 2005 23:24
Try printing the output as soon as you read it. You don't know the exact limit for T. So your program behaves abnormally for T>40.
Thanks a lot!
Posted by Alex Stoff 20 Sep 2005 19:51

Thank you! I got AC! Thanks.
Re: Thanks a lot!
Posted by zsyz_lyj 4 Mar 2009 10:35
Thanks