看板 PLT 關於我們 聯絡資訊
※ 引述《suhorng ( )》之銘言: : 不過那個結構[aka. data Free f a = Pure a | Impure (f (Free f a))] : 到底要怎麼推出來呢...? 各位板友新年快樂XD" 雖然年都要過完了 最近發現同一個作者還有另外幾篇介紹 Free Monad 的文章: http://www.haskellforall.com/2012/06/you-could-have-invented-free-monads.html http://www.haskellforall.com/2012/07/purify-code-using-free-monads.html 我覺得他給的程式範例解釋的很清楚, 也有小提及前幾篇文提到的list 另外, 關於 free monad 還有個很有趣的用 CPS 改進複雜度的介紹: http://www.haskell.org/haskellwiki/Performance/Monads (比較簡短的解釋: http://www.haskell.org/pipermail/haskell-cafe/2010-January/072454.html ) -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 118.166.44.154 ※ 編輯: suhorng 來自: 118.166.44.154 (02/04 22:17)