I hve an assignment to make

i have to make a C/C++ Program that automatically identifies any expression entered and solves the answer..

Example if i enter an expression like 3.14+(14-23*4/6)*7 it should evaulate it according to the precedence of the operator and give a numeric answer...

I need to generate a Grammar and then a parse tree and then finally evaluate that parse tree...but i dont know where to start and how to code.

please provide the source code and flowchart also (if possible)....