tails package:mono-traversable

Returns all the final segments of seq with the longest first.
> tails [1,2]
[[1,2],[2],[]]
> tails []
[[]]
Return all the pairs of inital and final segments of seq.
> initTails [1,2]
[([],[1,2]),([1],[2]),([1,2],[])]
> initTails []
[([],[])]