Created
May 9, 2012 01:59
-
-
Save rodrigovidal/2641193 to your computer and use it in GitHub Desktop.
Euler1 (revisado)
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
let euler1 (limit : int64) = | |
let limit = bigint (limit-1L) | |
let sn a1 = | |
let a1 = bigint (int a1) | |
let an = (limit / a1 * a1) | |
let n = an / a1 | |
(an + a1) * n / 2I | |
sn 3 + sn 5 - sn 15 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment