support for stdin/out
sort ends
when iterating, only include regions where the start-coordinate is in the current bin. Otherwise, you can have regions that cross bins get out of order.