Created
August 17, 2012 21:19
-
-
Save captainsafia/3382801 to your computer and use it in GitHub Desktop.
Solution to Project Euler Problem 15 in Python
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
def paths(n): | |
p=1 | |
for x in xrange(1, n+1): p=p*x | |
return p | |
print paths(40)/paths(20)/paths(20) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment