Commit 1065859c by BellCodeEditor

save project

parent 3a189b26
Showing with 10 additions and 2 deletions
...@@ -9,4 +9,13 @@ def sum_numbers(num): ...@@ -9,4 +9,13 @@ def sum_numbers(num):
temp = sum_numbers(num-1) temp = sum_numbers(num-1)
return num +temp return num +temp
result = sum_numbers(100) result = sum_numbers(100)
print(result) print(result)
\ No newline at end of file def func(n)
if n<=2:
return 1
elif n>=2:
pask=func(n-1)+func(n-2)
return Valure
result=func(6)
print(func(6))
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment