Created
May 15, 2014 20:43
-
-
Save goyuninfo/dab05a9ca23a82b1de41 to your computer and use it in GitHub Desktop.
project eluler problem 2 Even Fibonacci numbers
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
p,c=0,1 | |
s=0 | |
print s | |
while c<4000000: | |
print c | |
if c%2 ==0: | |
s=s+c | |
print s | |
p,c=c,p+c | |
print s |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment