とりあえず、Nil と Cons によるリストでmemptyとmappendを定義してみましたが、元々Haskell のリストはMonoidなので意味がありません。
import Data.Monoid data List a = Nil | Cons a (List a) deriving(Show) instance Monoid (List a) where mempty = Nil mappend Nil Nil = Nil mappend a Nil = a mappend Nil a = a mappend (Cons a b) c = Cons a (mappend b c) list = (Cons 1 Nil) `mappend` (Cons 2 Nil) `mappend` (Cons 3 Nil) -- > Cons 1 (Cons 2 (Cons 3 Nil)) list2 = list `mappend` mempty `mappend` (Cons 4 Nil) -- > Cons 1 (Cons 2 (Cons 3 (Cons 4 Nil)))
あとは Tree とか Queue でしょうか・・・。