1 2 3 4 5 6
applyN :: (a -> a) -> a -> Int -> a applyN f arg 1 = f arg applyN f arg count = f (applyN f arg (pred count))