Thoughts on 1
parent
bc3247a792
commit
8144edd676
|
@ -13,6 +13,9 @@ main = print ans
|
|||
ans :: Integer
|
||||
ans = sum $ allNumbersUnder 1000
|
||||
|
||||
sum' :: Num a => [a] -> a
|
||||
sum' = foldl (+) 0
|
||||
|
||||
isMultipleOf :: Integral a => a -> a -> Bool
|
||||
isMultipleOf n x = x `rem` n == 0
|
||||
|
||||
|
|
Loading…
Reference in New Issue