I was writing a bunch of ideas when this Algorithm library idea was announced. I've adapted some of them to pull requests:
- Detect how long a
Collectionkeeps being sorted. Plus, general binary search routines.
- When running two sequences in parallel, find the first corresponding pair that don't match. Or find their indexes when both are collections.
- Test if one sequence includes another. Works in either direction. Both sequences must be sorted.
- Merge two sorted sequences into a new sorted sequence. Or take a subset of the result.