Big Fibonacci Number

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

Fibonacci numbers are defined by the following relation:
f(0) = f(1) = 1,
f(n) = f(n - 1) + f(n - 2) for n > 1
You need to calculate f(n) mod 1000000000

Options

exec is denied

rejudge feature is enabled

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

Sample input:_

0
1
2
3
4
5

Sample output:

1
1
2
3
5
8

Sample input:_

123456
123456789
1000000000
999999999
42
1337
3600
777777777

Sample output:

986327937
449506095
460937501
560546875
433494437
785629944
960277601
171970439

Sample input:_

111111111
222222222
333333333
444444444
555555555
666666666
777777777
888888888
999999999

Sample output:

440574219
176136957
572218287
204431945
552118467
260185253
171970439
72897489
560546875

Ranking

Ruby _

RankUserSizeTimeDateStatistics
1mitchs870.04522016/05/22 11:33:090B / 40B / 41B

Ruby2 _

RankUserSizeTimeDateStatistics
1mitchs (tails)850.22872016/06/19 00:25:450B / 39B / 43B

Perl _

RankUserSizeTimeDateStatistics
1tails760.03632016/05/28 02:12:370B / 27B / 46B
2%201090.03672016/05/26 21:35:440B / 40B / 66B
3Hem1500.73832016/06/16 14:21:050B / 53B / 93B
4yuki3730.79452016/05/24 17:17:190B / 146B / 169B

Python _

RankUserSizeTimeDateStatistics
1mitchs1040.29312016/05/24 10:13:520B / 54B / 35B
2xnor1070.08912016/06/17 08:01:080B / ?B / ?B
3xsot1130.09532016/05/28 22:02:150B / 60B / 49B
4urupica1260.10702016/06/01 04:48:290B / ?B / ?B
5rolf1340.10042016/05/26 02:53:430B / 64B / 46B

JavaScript _

RankUserSizeTimeDateStatistics
1ETHproductions2030.08832016/06/14 01:06:540B / 146B / 56B

PARI/GP _

RankUserSizeTimeDateStatistics
1mitchs510.04242016/05/21 09:48:340B / 31B / 20B
2teebee510.03982016/05/21 20:05:020B / 31B / 20B
3Hendrik510.12562016/05/24 16:25:530B / 31B / 20B

C _

RankUserSizeTimeDateStatistics
1tails1290.03662016/05/27 19:12:140B / 67B / 59B
2mitchs1360.03192016/05/26 10:45:590B / 69B / 67B
3kimiyuki2430.03232016/06/17 19:02:510B / 122B / 120B
4mitchs (tails)1280.03222016/06/19 07:23:040B / 67B / 58B

Haskell _

RankUserSizeTimeDateStatistics
1henkma1140.04472016/05/30 22:40:350B / 57B / 52B
2yuki1570.03772016/05/23 14:11:550B / 76B / 70B
3nagibator20051660.03812016/05/23 07:23:320B / ?B / ?B

Bash (builtins) _

RankUserSizeTimeDateStatistics
1tails1160.08832016/05/25 17:15:120B / 44B / 62B

Zsh _

RankUserSizeTimeDateStatistics
1Hendrik640.25402016/05/29 23:08:420B / 31B / 31B

dc _

RankUserSizeTimeDateStatistics
1tails780.04022016/06/16 19:04:030B / 54B / 23B

Whitespace _

RankUserSizeTimeDateStatistics
1kaz_u2280.04712016/06/08 01:16:390B / 0B / 0B
2%202360.05502016/05/28 01:28:290B / 0B / 0B

GolfScript _

RankUserSizeTimeDateStatistics
1tails550.21822016/05/26 14:01:030B / 9B / 46B

gs2 _

RankUserSizeTimeDateStatistics
1mitchs320.59102016/05/26 16:17:2113B / 14B / 3B

Language Ranking_

RankLangUserSizeScore
1gs2mitchs3210000
2PARI/GPmitchs516274
3GolfScripttails555818
4ZshHendrik645000
5Perltails764210
6dctails784102
7Ruby2mitchs (tails)853764
8Rubymitchs873678
9Pythonmitchs1043076
10Haskellhenkma1142807
11Bash (builtins)tails1162758
12Cmitchs (tails)1282500
13JavaScriptETHproductions2031576
14Whitespacekaz_u2281403

return top