Microsoft interview question

Q 1 ) valid parentheses