Submission #155342
Source Code Expand
import Data.List main :: IO () main = do n <- readLn let tri = 1:1:zipWith3 (+) tri (tail tri) (tail $ tail tri) putStrLn . show . last $ take n tri
Submission Info
Submission Time | |
---|---|
Task | B - トリボナッチ数列 |
User | lmdexpr |
Language | Haskell (GHC 7.4.1) |
Score | 0 |
Code Size | 167 Byte |
Status | CE |
Compile Error
Main.hs:6:32: Occurs check: cannot construct the infinite type: c0 = c0 -> c0 Expected type: [c0 -> c0] Actual type: [c0] In the second argument of `zipWith3', namely `tri' In the second argument of `(:)', namely `zipWith3 (+) tri (tail tri) (tail $ tail tri)'