Clean up and rearrange
This commit is contained in:
9
fib_test/fib.py
Normal file
9
fib_test/fib.py
Normal file
@@ -0,0 +1,9 @@
|
||||
import sys
|
||||
def fib(n):
|
||||
if n == 0:
|
||||
return 1
|
||||
elif n == 1:
|
||||
return 1
|
||||
else:
|
||||
return fib(n-1) + fib(n-2)
|
||||
print(fib(int(sys.argv[1])))
|
||||
Reference in New Issue
Block a user