I am implementing a stack class to convert infix expressions to postfix expressions.
Program runs when I enter : (A*(B+C))
for example and gives me the correct ABC+*
But when I randomly entered (5+3)*3, I got a seg fault.
I suspect it's something in the actual algorithm.
Any ideas?
Here is the relevant code.
Edit: Code removed
Any ideas or pointers would be appreciated