AlgoSec interview question

LeetCode 71 - Simplify Path