merge algorithm, merge test, optimize copy_n and combine_copy_n for counted iterators