summaryrefslogtreecommitdiff
path: root/053.py
diff options
context:
space:
mode:
Diffstat (limited to '053.py')
-rw-r--r--053.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/053.py b/053.py
new file mode 100644
index 0000000..6e9461c
--- /dev/null
+++ b/053.py
@@ -0,0 +1,14 @@
+
+facs = [1]*101
+for i in range(1, 101):
+ facs[i] = facs[i-1] * i
+
+count = 0
+for n in range(23, 101):
+ for r in range(n+1):
+ x = facs[n] / (facs[r]*facs[n-r])
+ if x > 1000000:
+ count += 1
+
+print count
+