Sort List

Sort a linked list in O(n log n) time using constant space complexity.

Example :

Input : 1 -> 5 -> 4 -> 3

Returned list : 1 -> 3 -> 4 -> 5
Interview Code Editor
Hints
  • Solution Approach
  • Complete Solution
2789 successful submissions.
Asked In:
  • Google
Click here to jump start your coding interview preparation