Evaluation of Postfix with C++

habtamu's Avatar, Join Date: Jul 2008
Newbie Member
Dear Sir/Madam
Please Help me with this Problem. the Problem is Write a C++ Program to evaluate Postfix notation,here is the prototype.
Code:
struct charNode
{
char data;
charNode *next;
};
struct intNode
{
int data;
intNode *next;
};
void readInput(charNode*&);
void reverseInput(charNode*&,intNode*&);
void evaluate(charNode*,intNode*&);
void displayResult(intNode*);
int isoperator(char);
void createchar(charNode*&);
void createInt(intNode*&);
void pushchar(charNode*&);
void pushInt(intNode*&,int);
char popchar(charNode*&);
int popInt(intNode*&);
int isEmpty(charNode*);
int isEmpty(intNode*);
void main()
{
charNode *charTopOriginal,*charTopReversed;
intNode *intTop;
create char(charTopOriginal);
create char(charTopReversed);
create Int(intTop);
readeInput(charTopOriginal);
reversedInput(charTopOriginal,charTopReversed);
evaluate(charTopOriginal,charTopReversed);
displayResult(intTop);
getch();
}

Last edited by shabbir; 18Jul2008 at 17:22.. Reason: Code block
0
xpi0t0s's Avatar, Join Date: Aug 2004
Mentor
Sure, no problem. My rates are GBP100/hour, minimum 4 hours. For no extra charge I'll submit the work directly to tour teacher if you give me their email address. I'll need a few more details (example input and output) if you decide to go ahead.
0
shabbir's Avatar, Join Date: Jul 2004
Go4Expert Founder
Quote:
Originally Posted by xpi0t0s
Sure, no problem. My rates are GBP100/hour, minimum 4 hours. For no extra charge I'll submit the work directly to tour teacher if you give me their email address. I'll need a few more details (example input and output) if you decide to go ahead.
Search the forum and you may save 400 GBP.
0
aali's Avatar, Join Date: Jul 2008
Go4Expert Member
Why don't you use a Stack or queue?