1 2 3 4 5 6 7 8 | head' :: [a] -> a head' (x:_) = x -- Pattern match(es) are non-exhaustive In an equation for `head'': Patterns not matched: [] length2' :: (Num b) => [a] -> b length2' [] = 0 --Pattern match(es) are non-exhaustive In an equation for `length2'': Patterns not matched: _ : (_ : _) length2' [x] = 1 + (length2' (tail [x])) |
aGVhZCcgOjogW2FdIC0+IGEKaGVhZCcgKHg6XykgPSB4IC0tIFBhdHRlcm4gbWF0Y2goZXMpIGFyZSBub24tZXhoYXVzdGl2ZSAgICAgICAgICAgIEluIGFuIGVxdWF0aW9uIGZvciBgaGVhZCcnOiBQYXR0ZXJucyBub3QgbWF0Y2hlZDogW10KCgpsZW5ndGgyJyA6OiAoTnVtIGIpID0+IFthXSAtPiBiCmxlbmd0aDInIFtdID0gMCAtLVBhdHRlcm4gbWF0Y2goZXMpIGFyZSBub24tZXhoYXVzdGl2ZSAgICAgICAgICAgICBJbiBhbiBlcXVhdGlvbiBmb3IgYGxlbmd0aDInJzogUGF0dGVybnMgbm90IG1hdGNoZWQ6IF8gOiAoXyA6IF8pCmxlbmd0aDInIFt4XSA9IDEgKyAobGVuZ3RoMicgKHRhaWwgW3hdKSkK
[1 of 1] Compiling Main ( prog.hs, prog.o ) prog.hs:1:0: The function `main' is not defined in module `Main'
-
result: Compilation error (maybe you wish to see an example for Haskell)



