Simplify unix path in place

I was recently asked this question in the Microsoft interview. Is there any way to do this inplace in O(n) time ?

https://leetcode.com/problems/simplify-path/

Comments (0)