Problems with tag O(nlogn)