Given a range of ranges where individual ranges are already sorted, is there anything in Phobos that can visit the combined range in sorted order?

Although the range elements are not necessarily arrays, e.g.

    [ [ 3, 10, 20 ]
      [ 1, 2, 7 ]
      [ 5, 6 ] ]

The elements should appear without any copying as

    [ 1, 2, 3, 5, 6, 7, 10, 20 ]

The outer range may be unsorted but luckily it has very few elements so a linear search should be fine.

Ali

Reply via email to