title: Pushdown Automata for the Language of Both Balanced Parentheses and Brackets
body: <p>I need to figure out a pushdown automata for constructing strings of the language of both balanced parentheses and brackets, such as this ((([()))])()[]. It seems pretty easy to do for one type of parentheses; your stack consists of ( that you push when you see them, and then you pop one off for each ) you see. However, I'm having trouble figuring it out for the two types of parentheses. Does anyone have any suggestions? Thanks.</p>