Meta interview question

Leet code 71. Simplify Path