Get rid of the sorting. No need to check both ways current -> next, next
-> current.