I found this implementation of the average function:
avg :: [Int] -> Int
avg = div . sum <*> length
How does this work? I looked at the function that was produced as a result of div . sum:
(div . sum) :: (Integral a, Foldable t) => t a -> a -> a
I understand that, but I'm unable to tell how <*> length does the work.