aboutsummaryrefslogtreecommitdiff
path: root/problem97.erl
blob: 5a7f6b6d2cc823608e2e7fcf2c203f1513733bfa (plain)
1
2
3
4
5
6
7
8
-module(problem97).
-export([solve/0]).

solve() -> (28433 * pow(7830457))+1.

pow(E) -> pow2(2,E).
pow2(B,1) -> B;
pow2(B,E) -> pow2(2*B, E-1).