**Packages**- bytestring
- text
- base
- containers

scanl is similar to foldl, but returns a list of successive reduced values from the left:
> scanl f z [x1, x2, ...] == [z, z `f` x1, (z `f` x1) `f` x2, ...]
Note that
> last (scanl f z xs) == foldl f z xs.

scanl is similar to foldl, but returns a sequence of reduced values from the left:
> scanl f z (fromList [x1, x2, ...]) = fromList [z, z `f` x1, (z `f` x1) `f` x2, ...]