08.08.07

Exercise 9.4

Posted in Uncategorized at 10:34 pm by admin

applyEach :: [(a -> b)] -> a -> [b]
applyEach [] _ = []
applyEach (f:fs) x = f x : applyEach fs x

1 Comment »

  1. anonyoumous said,

    February 21, 2008 at 12:52 pm

    applyEach fs x = map (\f -> f x) fs
    or using ($)
    applyEach fs x = map ($ x) fs

Leave a Comment