ghc haskell version and go for e1
This commit is contained in:
parent
bf1adf6b06
commit
9e2179f2d8
|
@ -0,0 +1,4 @@
|
||||||
|
*.exe
|
||||||
|
*.o
|
||||||
|
*.swp
|
||||||
|
*.hi
|
|
@ -0,0 +1,7 @@
|
||||||
|
import System.IO
|
||||||
|
|
||||||
|
sum35 i acc max | i >= max = acc
|
||||||
|
| rem i 3 == 0 ||rem i 5 == 0 = sum35 (i+1) (acc+i) max
|
||||||
|
| otherwise = sum35 (i+1) acc max
|
||||||
|
|
||||||
|
main = print (sum35 1 0 1000)
|
Loading…
Reference in New Issue