I'm completely stuck trying to implement this function below in a simple tutorial exercise. It should apply the second parameter to the last parameter, and then apply the first parameter to the whole thing:
multiApp sum [(1+), (^3), (+2)] 1 ==> 6
multiApp reverse [tail, take 2, reverse] "foo" ==> ["oof","fo","oo"]
Since the function can return a single element or list, I don't know how to define it, something like this as a start won't even compile:
multiApp :: (β->β) -> [(β->β)] -> β -> β
multiApp f fs x = f $ map (\i -> i x) fs