Generate parenthesis problem