Python paranthesis checker