2011-11-30から1日間の記事一覧
Gist test
お休みを貰うことができたのでプールに行きました。30分泳いでいました。
As this blog doesn't support "super-pre notation", I go back to suztomoの日記 - haskell.
myfoldr :: (a -> b -> b) -> b -> [a] -> b myfoldr f b alst = case alst of a : rst -> f a (foldr f b rst) _ -> b myfoldl :: (a -> b -> a) -> a -> [b] -> a myfoldl f a blst = case blst of b : rst -> myfoldl f (f a b) rst _ -> a myreverse :: …