diff --git a/primes.py b/primes.py index 7b625e3..3ba8b7b 100644 --- a/primes.py +++ b/primes.py @@ -134,4 +134,4 @@ def demo(): if __name__ == '__main__': demo() - + # this is the main funtion that is called when the script is run. diff --git a/problem_2.py b/problem_2.py index 0b75a3c..de69aea 100644 --- a/problem_2.py +++ b/problem_2.py @@ -6,6 +6,7 @@ while True: fibo.append(fibo[-1]+fibo[-2]) - if fibo[-1]>4000000: break + if fibo[-1]>4000000: + break print sum(filter(lambda x:x%2==0,fibo))