我有以下代码给出[2,4,6]:
[2,4,6]
j :: [Int] j = ((\f x -> map x) (\y -> y + 3) (\z -> 2*z)) [1,2,3]
为什么?似乎只使用了“z 函数”,“y 函数”会发生什么?map在这种特殊情况下如何工作?
map
haskell function function-call map-function
function ×1
function-call ×1
haskell ×1
map-function ×1