Write a small program that checks for matching brackets. For example, the program would return true if it were given "( ( { ( { [ ] } ) } ) )" where all brackets pair correctly as they would in a program, and return false for something like "( ( [ ] )" or "( [ ) ]".
Anónimo
Use a stack and push open brackets on it and pop when you see a close bracket. When did you interview and did you answer the question successfully?