1
0
forked from tdwojak/Python2017

Praca domowa nr 2

Rozwiązanie - Piotr Bystrzycki - nr indeksu 45146
This commit is contained in:
s45146 2017-12-03 14:50:19 +01:00
parent ee29b2e399
commit 233a2250f6

13
labs03/task02.py Normal file
View File

@ -0,0 +1,13 @@
def Fibogen(n):
if n == 0:
ret = yield 1
if n == 1:
ret = yield 1
for i in range(n+1):
ret = yield (Fibogen(n-2) + Fibogen(n-1))
return ret
for i in Fibogen(4):
print(i)