Help me to show step by step solution infix to postfix

the code is running but my professor told me to modify the code. he need to see the step by step conversion of infix to postfix. the problem is i don't know how to show the step by step conversion..
(a+b )/(a-b )
a+b / a-b
a+b a-b/
ab+ ab-/

#define STACK_SIZE 100
using namespace std;

char stackChar[STACK_SIZE];
int top=-1;

void push(char c);
char pop();

int main()

char expr[STACK_SIZE], postfixexpr[STACK_SIZE];
cout << "Enter the exp<b>ression: ";


int j=0;

for(int i=0;i0");
return 0;


void push(char c)
stackChar[++top] = c;

char pop()
return stackChar[top--];
Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!