MicroStrategy Interview Question

1. Code a tool to check if all the paranthesis are closed.