我不明白this-- Prelude> "hi"++"there"
"hithere"
Prelude> "hi":"there"
<interactive>:12:6:
Couldn't match expected type `[Char]' with actual type `Char'
Expected type: [[Char]]
Actual
我正在學習Haskell,當我遇到非常令人費解的事情時,我在ghci中玩耍。 首先,創建一個簡單的附加功能: Prelude> let add x y = x + y
注意,它與整型和浮點: Prelude> add 3 4
7
Prelude> add 2.5 1.3
3.8
現在創建一個應用功能。它與$(但不是中綴)相同。它像一個無操作上添加: Prelude> let appl