Balancing Symbols

I am working on a class discussion in which I am to write a program that checks to see if /* */, ( ), { }, [ } symbols are balanced. If the balancing symbols are not balanced, then I am to try to pinpoint the problem section of the code. I am working on using stacks although it does not require the use of stacks, but that is what the chapters for that part of the class have covered. I also think that it the program can be done using strings. Are there better ways of doing this?

Thank you,
Topic archived. No new replies allowed.