All Problems

Remove Duplicates from Sorted List

Easylinked-listExpected: O(n) time, O(1) spaceInterview Context
sorting

Problem

Given the head of a sorted linked list, delete all duplicates such that each element appears only once.

Loading...