Removed sorting from sequential on insert (redundant)
Created sortedpairs type — needs new name