update meta data
This commit is contained in:
parent
f3a896c724
commit
90e15ed6ce
3307 changed files with 1674 additions and 7 deletions
23
Task/Fibonacci-sequence/00DESCRIPTION
Normal file
23
Task/Fibonacci-sequence/00DESCRIPTION
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
The '''Fibonacci sequence''' is a sequence F<sub>n</sub> of natural numbers defined recursively:
|
||||
F<sub>0</sub> = 0
|
||||
F<sub>1</sub> = 1
|
||||
F<sub>n</sub> = F<sub>n-1</sub> + F<sub>n-2</sub>, if n>1
|
||||
|
||||
Write a function to generate the nth Fibonacci number. Solutions can be iterative or recursive (though recursive solutions are generally considered too slow and are mostly used as an exercise in recursion).
|
||||
|
||||
The sequence is sometimes extended into negative numbers by using a straightforward inverse of the positive definition:
|
||||
|
||||
F<sub>n</sub> = F<sub>n+2</sub> - F<sub>n+1</sub>, if n<0
|
||||
|
||||
Support for negative n in the solution is optional.
|
||||
|
||||
;Cf.:
|
||||
* [[Fibonacci n-step number sequences]]
|
||||
|
||||
;References:
|
||||
* [[wp:Fibonacci number|Wikipedia, Fibonacci number]]
|
||||
* [[wp:Lucas number|Wikipedia, Lucas number]]
|
||||
* [http://mathworld.wolfram.com/FibonacciNumber.html MathWorld, Fibonacci Number]
|
||||
* [http://www.math-cs.ucmo.edu/~curtisc/articles/howardcooper/genfib4.pdf Some identities for r-Fibonacci numbers]
|
||||
*[[oeis:A000045|OEIS Fibonacci numbers]]
|
||||
*[[oeis:A000032|OEIS Lucas numbers]]
|
||||
Loading…
Add table
Add a link
Reference in a new issue