你好,我是 Haskell 的新手,我创建了这段代码来附加两个列表。但我会得到一个解析错误。我究竟做错了什么?
import Data.List
-- list a + list b = list c
joinList :: [a] -> [a] -> [a]
joinList a + b = c
where
a = ["example1","example2","example3"]
b = ["example4","example4","example5"]
c = a ++ b
错误:
test2.hs:5:1: `Parse error in pattern: joinList`