Reves Puzzle

Submit

Your name:
File:
Open code-statistics:

Language is selected by the extension of the file. See the list of supported languages to know the extension of your language.

Problem

Compute the number of moves needed to solve the Towers of Hanoi puzzle with 4 pegs and n disks, according to the Frame-Stewart algorithm.
--teebee

Options

exec is denied

now post-mortem time, all source codes will be revealed

Sample input:_

*NOTHING*

Sample output:

0
1
3
5
9
13
17
25
33
41
49
65
81
97
113
129
161
193
225
257
289
321
385
449
513
577
641
705
769
897
1025
1153
1281
1409
1537
1665
1793
2049
2305
2561
2817
3073
3329
3585
3841
4097
4609
5121
5633
6145
6657
7169
7681
8193
8705
9217
10241
11265
12289
13313
14337
15361
16385
17409
18433
19457
20481
22529
24577
26625
28673
30721
32769
34817
36865
38913
40961
43009
45057
49153
53249
57345
61441
65537
69633
73729
77825
81921
86017
90113
94209
98305
106497
114689
122881
131073
139265
147457
155649
163841
172033
180225
188417
196609
204801
212993
229377
245761
262145
278529
294913
311297
327681
344065
360449
376833
393217
409601
425985
442369
458753
491521
524289
557057
589825
622593
655361
688129
720897
753665
786433
819201
851969
884737
917505
950273
983041
1048577
1114113
1179649
1245185
1310721
1376257
1441793
1507329
1572865
1638401
1703937
1769473
1835009
1900545
1966081
2031617
2097153
2228225
2359297
2490369
2621441
2752513
2883585
3014657
3145729
3276801
3407873
3538945
3670017
3801089
3932161
4063233
4194305
4325377
4456449
4718593
4980737
5242881
5505025
5767169
6029313
6291457
6553601
6815745
7077889
7340033
7602177
7864321
8126465
8388609
8650753
8912897
9175041
9437185
9961473

Ranking

Ruby _

RankUserSizeTimeDateStatistics
1clock370.01032013/09/06 09:54:451B / 14B / 21B
2teebee370.00922013/09/07 23:05:281B / 14B / 21B
3Histocrat400.00762013/09/06 07:33:040B / 22B / 14B

Perl _

RankUserSizeTimeDateStatistics
1teebee390.01122013/09/05 23:13:350B / 18B / 20B
2tails390.01422013/09/06 01:07:190B / 18B / 20B
3primo (alt)390.00022013/09/06 01:17:570B / 18B / 20B
4Hem390.00012013/09/06 10:36:350B / 20B / 19B
5brx(alt)400.01702013/09/10 01:51:440B / 19B / 20B
6primo430.00012013/09/05 20:43:230B / 13B / 29B
7brx440.00012013/09/06 18:09:470B / 20B / 23B

Python _

RankUserSizeTimeDateStatistics
1leonid440.03322013/09/06 10:16:340B / 24B / 18B
2clock440.03832013/09/16 18:41:530B / 24B / 19B
3primo490.03682013/09/05 22:07:020B / 26B / 22B
4teebee490.07832013/09/06 01:21:520B / 26B / 22B
5hallvabo560.03952013/09/07 11:05:250B / 30B / 26B
6malkovich570.05452013/09/07 00:53:260B / 28B / 26B
7rolf740.03652013/09/05 20:50:570B / 41B / 22B
8heap2750.06202013/10/04 10:54:180B / 115B / 55B

PHP _

RankUserSizeTimeDateStatistics
1primo450.03042013/09/05 22:13:561B / 21B / 23B
2teebee450.01822013/09/07 21:48:531B / 21B / 23B

Io _

RankUserSizeTimeDateStatistics
1clock450.07582013/09/18 22:17:110B / 24B / 20B
2teebee470.09292013/09/06 06:54:390B / 25B / 21B
3pooq530.08482013/09/07 09:37:580B / 31B / 21B

JavaScript _

RankUserSizeTimeDateStatistics
1clock430.05722013/09/16 20:23:320B / 23B / 20B
2copy450.01182013/09/05 08:18:530B / 22B / 23B
3Shmiddty450.05272013/09/06 00:17:490B / 23B / 22B
4_nderscore (~)450.01532013/09/08 14:54:260B / 22B / 23B

Lua _

RankUserSizeTimeDateStatistics
1clock550.01582013/09/18 21:35:350B / 32B / 18B

Xtal _

RankUserSizeTimeDateStatistics
1clock430.01912013/09/16 20:25:050B / 21B / 21B
2teebee470.01722013/09/17 15:48:520B / 26B / 21B
3pooq500.11032013/09/07 08:38:190B / 28B / 21B

Kite _

RankUserSizeTimeDateStatistics
1teebee880.01442014/11/17 02:03:120B / 53B / 35B

REXX _

RankUserSizeTimeDateStatistics
1clock480.00012013/09/07 02:57:130B / 28B / 11B
2teebee480.01022013/09/07 07:38:140B / 28B / 11B

PARI/GP _

RankUserSizeTimeDateStatistics
1clock420.02262013/09/18 20:28:450B / 24B / 18B
2teebee430.03442013/09/07 07:04:040B / 20B / 23B

BASIC _

RankUserSizeTimeDateStatistics
1clock400.00522013/09/16 20:30:220B / 22B / 18B
2teebee420.01092013/09/06 07:07:000B / 25B / 14B
3pooq490.01102013/09/07 14:30:490B / 31B / 12B

J _

RankUserSizeTimeDateStatistics
1I., S.230.02262013/09/07 23:12:220B / 10B / 13B
2pooq240.21492013/09/06 23:12:460B / 11B / 13B

A+ _

RankUserSizeTimeDateStatistics
1teebee280.02922013/09/07 00:13:279B / 10B / 9B

K _

RankUserSizeTimeDateStatistics
1teebee180.01052013/09/06 23:17:180B / 8B / 10B
2clock180.01052013/09/16 20:10:560B / 7B / 11B

C _

RankUserSizeTimeDateStatistics
1ush600.01372013/09/11 09:23:250B / 30B / 30B
2clock600.00012013/09/18 22:06:280B / 30B / 30B

Haskell _

RankUserSizeTimeDateStatistics
1malkovich590.01052013/09/08 15:12:370B / 32B / 25B
2I., S.600.01082013/09/08 06:21:150B / 33B / 25B
3nooodl620.01272013/09/08 22:54:320B / ?B / ?B
4nooodl(malkovich)580.01772013/09/21 18:13:490B / ?B / ?B

Java _

RankUserSizeTimeDateStatistics
1clock790.08322013/09/16 20:17:560B / 45B / 32B
2teebee860.07802013/09/12 07:01:480B / 51B / 33B

Fortran _

RankUserSizeTimeDateStatistics
1teebee570.00012013/09/15 22:55:030B / 31B / 24B

Maxima _

RankUserSizeTimeDateStatistics
1teebee530.11062013/09/06 23:33:520B / 30B / 23B
2clock530.11852013/09/07 00:28:020B / 30B / 23B
3pooq621.19482013/09/06 19:47:520B / 38B / 21B

Octave _

RankUserSizeTimeDateStatistics
1teebee480.22252013/09/12 05:54:100B / 27B / 21B

Asymptote _

RankUserSizeTimeDateStatistics
1clock490.09402013/09/18 15:33:150B / 28B / 20B
2teebee510.09232013/09/15 10:39:400B / 29B / 21B

AWK _

RankUserSizeTimeDateStatistics
1teebee410.01062013/09/07 21:21:400B / 22B / 19B
2clock410.01062013/09/16 23:17:300B / 24B / 17B
3eban560.01522013/09/06 10:47:060B / 31B / 24B

bc _

RankUserSizeTimeDateStatistics
1teebee320.01322013/09/07 20:53:470B / 12B / 19B
2clock320.01052013/09/08 23:08:350B / 13B / 18B

R _

RankUserSizeTimeDateStatistics
1pooq440.19772013/09/06 23:35:160B / 25B / 18B
2teebee440.14852013/09/06 23:48:410B / 25B / 18B
3clock440.15082013/09/16 19:37:540B / 27B / 17B

QCL _

RankUserSizeTimeDateStatistics
1clock600.03212013/09/16 18:19:340B / 35B / 21B
2teebee610.01222013/09/15 11:49:380B / 37B / 19B

GolfScript _

RankUserSizeTimeDateStatistics
1whio250.02852013/09/19 04:04:450B / 6B / 19B
2tails260.04552013/09/05 22:58:101B / 7B / 18B

Groovy _

RankUserSizeTimeDateStatistics
1clock480.91912013/09/17 00:50:410B / 27B / 20B

Scala _

RankUserSizeTimeDateStatistics
1clock592.86322013/09/18 14:26:070B / 34B / 20B
2teebee612.87162013/09/17 07:50:150B / 35B / 21B

Logo _

RankUserSizeTimeDateStatistics
1teebee510.01822013/09/06 16:29:340B / 31B / 13B
2clock510.02252013/09/06 17:03:060B / 31B / 13B

Language Ranking_

RankLangUserSizeScore
1Kteebee1810000
2JI., S.237826
3GolfScriptwhio257200
4A+teebee286428
5bcteebee325625
6Rubyclock374864
7Perlteebee394615
8BASICclock404500
9AWKteebee414390
10PARI/GPclock424285
11JavaScriptclock434186
12Xtalclock434186
13Pythonleonid444090
14Rpooq444090
15PHPprimo454000
16Ioclock454000
17REXXclock483750
18Octaveteebee483750
19Groovyclock483750
20Asymptoteclock493673
21Logoteebee513529
22Maximateebee533396
23Luaclock553272
24Fortranteebee573157
25Haskellnooodl(malkovich)583103
26Scalaclock593050
27Cush603000
28QCLclock603000
29Javaclock792278
30Kiteteebee882045

return top