The remove operation is O(n), TreeSet is what you are looking for.
And apart from that, there is another issue (probably a reminder).
The remove operation itself is calling equals() rather than Arrays.equals() or Arrays.deepEquals()
The Skyline Problem
Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.