6 kyu

Fibonacci Reloaded

1,001 of 2,290BattleRattle

Description:

And here is Fibonacci again. This time we want to go one step further. Our fib() function must be faster! Can you do it?

In case you don't know, what the Fibonacci number is:

The nth Fibonacci number is defined by the sum of the two previous Fibonacci numbers. In our case: fib(1) := 0 and fib(2) := 1. With these initial values you should be able to calculate each following Fibonacci number.

Examples:

fib(1) // === 0
fib(2) // === 1
fib(3) // === 1
fib(4) // === 2
fib(5) // === 3
Algorithms

Stats:

CreatedOct 9, 2013
PublishedOct 9, 2013
Warriors Trained3747
Total Skips222
Total Code Submissions8836
Total Times Completed2290
JavaScript Completions1167
Ruby Completions107
Python Completions1001
Haskell Completions75
Total Stars61
% of votes with a positive feedback rating89% of 459
Total "Very Satisfied" Votes375
Total "Somewhat Satisfied" Votes64
Total "Not Satisfied" Votes20
Ad
Contributors
  • BattleRattle Avatar
  • jhoffner Avatar
  • GiacomoSorbi Avatar
  • anter69 Avatar
  • JohanWiltink Avatar
  • Firefly2002 Avatar
  • user9644768 Avatar
  • cliffstamp Avatar
  • Just4FunCoder Avatar
  • saudiGuy Avatar
Ad