Fibonacci-Berechnung korrigiert.

This commit is contained in:
2023-07-09 16:47:14 +02:00
parent 9956835ad9
commit 63fee8c895
7 changed files with 11 additions and 9 deletions

View File

@@ -6,7 +6,7 @@ def fib(n):
# Rekursionsbedingung
if n in [0,1]:
return 1
return n
else:
# Rekursionsaufruf
return fib(n-1) + fib(n-2)