Welcome to fibonacci’s documentation!¶
Contents:
- fib.fib(n)¶
Return the first Fibonacci number above n.
Iteratively calculate Fibonacci numbers until it finds one greater than n, which it then returns.
- Parameters:
- ninteger
The minimum threshold for the desired Fibonacci number.
- Returns:
- binteger
The first Fibonacci number greater than the input, n.
Examples
>>> fib.fib(1) 2 >>> fib.fib(3) 5