6 lines
149 B
Haskell
6 lines
149 B
Haskell
main :: IO()
|
|
main = do
|
|
print (sum ret)
|
|
where
|
|
fibs = 1 : 2 : zipWith (+) fibs (tail fibs)
|
|
ret = filter even (takeWhile (<= 4000000) fibs)
|