summaryrefslogtreecommitdiffstats
path: root/97.bc
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2009-05-16 02:34:07 -0500
committerJesse Luehrs <doy@tozt.net>2009-05-16 02:34:07 -0500
commitdfd12e7ad72bb5cc5c8c4dd3b9a634137e115e06 (patch)
tree76aeccc78013e956b6065f8a1dfc24f2be39435e /97.bc
parent198cd9dce336d921f504fc11e03fce6ed906aec9 (diff)
downloadprojecteuler-dfd12e7ad72bb5cc5c8c4dd3b9a634137e115e06.tar.gz
projecteuler-dfd12e7ad72bb5cc5c8c4dd3b9a634137e115e06.zip
problem 97 solution
Diffstat (limited to '97.bc')
-rw-r--r--97.bc10
1 files changed, 10 insertions, 0 deletions
diff --git a/97.bc b/97.bc
new file mode 100644
index 0000000..c0c5c26
--- /dev/null
+++ b/97.bc
@@ -0,0 +1,10 @@
+#!/usr/bin/bc
+
+accum = 1
+for (i = 0; i < 7830457; i++) {
+ accum *= 2
+ scale = 0
+ accum = accum % 10^10
+ scale = 20
+}
+28433 * accum + 1