Prime differences
Submit
Language is selected by the extension of the file. See the list of supported languages to know the extension of your language.
Problem
If n is the difference between consecutive primes, print the nth prime for the first 100 primes.
i.e.
2, 3 - difference 1, print 1st prime (2)
3, 5 - difference 2, print 2nd prime (3)
...
523, 541 - difference 18, print 18th prime (61)
- Volatility
Options
exec is denied
now post-mortem time, all source codes will be revealed
Sample input:_
*NOTHING*
Sample output:
2
3
3
7
3
7
3
7
13
3
13
7
3
7
13
13
3
13
7
3
13
7
13
19
7
3
7
3
7
43
7
13
3
29
3
13
13
7
13
13
3
29
3
7
3
37
37
7
3
7
13
3
29
13
13
13
3
13
7
3
29
43
7
3
7
43
13
29
3
7
13
19
13
13
7
13
19
7
19
29
3
29
3
13
7
13
19
7
3
7
37
19
7
19
7
13
37
3
61
Ranking
Rank | User | Size | Time | Date | Statistics |
---|
1 | Histocrat | 62 | 0.0236 | 2013/02/22 22:41:49 | 0B / 41B / 17B |
2 | jpl | 74 | 0.0463 | 2013/03/01 08:09:26 | 0B / ?B / ?B |
Rank | User | Size | Time | Date | Statistics |
---|
1 | hallvabo | 68 | 0.0669 | 2013/02/26 07:09:02 | 0B / 38B / 28B |
2 | leonid | 68 | 0.0619 | 2013/02/26 08:26:27 | 0B / 36B / 28B |
3 | recursive | 96 | 0.0375 | 2013/02/23 08:44:19 | 0B / 58B / 24B |
4 | Volatility | 98 | 0.0421 | 2013/02/23 09:12:14 | 1B / 59B / 24B |
5 | leonid | 64 | 0.0649 | 2013/03/09 04:00:43 | 0B / 34B / 28B |
Rank | User | Size | Time | Date | Statistics |
---|
1 | kaki | 106 | 0.0815 | 2013/03/07 13:00:51 | 0B / 51B / 45B |
2 | kaki | 105 | 0.0753 | 2013/03/25 04:45:10 | 0B / 49B / 47B |
Rank | User | Size | Time | Date | Statistics |
---|
1 | pooq | 111 | 0.2919 | 2013/03/07 20:07:58 | 0B / 62B / 47B |
Rank | User | Size | Time | Date | Statistics |
---|
1 | pooq | 97 | 0.1197 | 2013/03/08 11:09:58 | 0B / 50B / 47B |
Rank | User | Size | Time | Date | Statistics |
---|
1 | teebee | 41 | 0.0096 | 2013/02/23 05:48:06 | 0B / 24B / 16B |
2 | clock | 41 | 0.0089 | 2013/02/23 23:12:11 | 0B / 24B / 17B |
Rank | User | Size | Time | Date | Statistics |
---|
1 | pooq | 106 | 0.1277 | 2013/03/07 17:27:30 | 0B / 64B / 30B |
Rank | User | Size | Time | Date | Statistics |
---|
1 | random | 19 | 0.0422 | 2013/02/22 23:16:56 | 0B / ?B / ?B |
2 | pooq | 19 | 0.0186 | 2013/02/22 23:34:01 | 0B / 9B / 10B |
3 | Colin Benner | 23 | 0.0169 | 2013/02/28 20:33:01 | 0B / 9B / 14B |
4 | va | 30 | 0.0211 | 2013/02/23 08:57:10 | 0B / ?B / ?B |
5 | medialuna | 27 | 0.0201 | 2014/08/18 17:46:32 | 0B / ?B / ?B |
Rank | User | Size | Time | Date | Statistics |
---|
1 | clock | 68 | 0.0896 | 2013/02/24 23:35:09 | 0B / 42B / 26B |
2 | teebee | 68 | 0.1064 | 2013/02/25 00:21:04 | 0B / 42B / 26B |
3 | pooq | 84 | 0.1781 | 2013/02/22 23:08:15 | 0B / 56B / 24B |
Rank | User | Size | Time | Date | Statistics |
---|
1 | teebee | 37 | 0.2351 | 2013/02/23 21:56:42 | 0B / 23B / 14B |
2 | inaniwa | 37 | 0.2489 | 2013/02/23 22:44:20 | 0B / 23B / 14B |
3 | pooq | 39 | 0.2344 | 2013/02/22 22:26:40 | 0B / 24B / 15B |
Rank | User | Size | Time | Date | Statistics |
---|
1 | rolf (bin) | 169 | 0.7242 | 2013/02/24 00:16:48 | 41B / 77B / 39B |
2 | rolf | 286 | 0.7005 | 2013/02/23 05:28:47 | 0B / 171B / 30B |
Rank | User | Size | Time | Date | Statistics |
---|
1 | clock | 48 | 0.1955 | 2013/03/08 20:08:30 | 0B / 25B / 23B |
2 | pooq | 61 | 0.1984 | 2013/03/08 20:55:44 | 0B / 29B / 32B |
3 | clock | 42 | 0.1685 | 2013/03/08 21:15:23 | 0B / 24B / 18B |
Language Ranking_
Rank | Lang | User | Size | Score |
1 | J | random | 19 | 10000 |
2 | Octave | teebee | 37 | 5135 |
3 | PARI/GP | teebee | 41 | 4634 |
4 | R | clock | 42 | 4523 |
5 | Perl | teebee | 59 | 3220 |
6 | Ruby | Histocrat | 62 | 3064 |
7 | Python | leonid | 64 | 2968 |
8 | Maxima | clock | 68 | 2794 |
9 | Haskell | henkma | 76 | 2500 |
10 | Xtal | pooq | 97 | 1958 |
11 | Scheme | kaki | 105 | 1809 |
12 | BASIC | pooq | 106 | 1792 |
13 | Io | pooq | 111 | 1711 |
14 | Postscript | rolf (bin) | 169 | 1124 |
return to the top page