Microsoft interview question

Array manipulation problems, dfs. The easiest was very similar to valid parenthesis on LeetCode.