Generate Valid Parentheses Leetcode Python Compiler