I want to input operater like “* / -“

145 pts.
Tags:
C++
hi I want to make a program enter value : 2*2/5(5*5)^2-5+69 and want the output of this calculation

Answer Wiki

Thanks. We'll let you know when a new response is added.

Please describe the specific problems/doubts you are having, so we can provide bettter help.

In general, you will need a scanner to scan/parse the input string, and you will probably need to use postfix notation which will require the use of some LIFO (stack) structures.

Discuss This Question: 1  Reply

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • G2
    you can use a stack to convert this expression to postfix expression and then you can calculate that postfix expression using push and pop to the stack.
    15 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following