Find the Corrupt Pair

Try to solve the Find the Corrupt Pair problem.