We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 98a149e commit 74e94abCopy full SHA for 74e94ab
project_euler/problem_25/sol2.py
@@ -0,0 +1,10 @@
1
+def fibonacci_genrator():
2
+ a, b = 0,1
3
+ while True:
4
+ a,b = b,a+b
5
+ yield b
6
+answer = 1
7
+gen = fibonacci_genrator()
8
+while len(str(next(gen))) < 1000:
9
+ answer += 1
10
+assert answer+1 == 4782
0 commit comments