Convert following infix expression to the prefix expression.
a - b + c * (d / e - (f + g))
Answers were Sorted based on User's Feedback
Answer / p.divya poojitha
a-b+c*(/de-(+fg))
a-b+c*(t-s) if t=/de;s=+fg
a-b+c*(-ts)
-ab+*c-ts
+-ab*c-ts
sol is +-ab*c-/de+fg
| Is This Answer Correct ? | 0 Yes | 1 No |
Answer / deepshikha singh
first we solve() because it has greatest priority
step1 : a-b+c*(d/e-[+fg])
step2 : a-b+c*([/de]-[+fg])
step3 : a-b+c*[-/de+fg]
step4 : a-b+[*c-/de+fg]
step5 : a-[+b*c-/de+fg]
step6: -a+b*c-/de+fg
note :[] sign is use to differentiate two terms after applying
operations.
| Is This Answer Correct ? | 3 Yes | 9 No |
Answer / amit patra
=a-b+c*(d/e-(+fg)
=a-b+c*(/de-(+fg)
=a-b+c*(-/de+fg)
=a-b+c*-de+fg
=-ab+c*-de+fg
=*-+abcde+fg
| Is This Answer Correct ? | 1 Yes | 13 No |
Answer / piyush kumar
a-b+c*(d/e-(f+g))
=a-b+c*(/de-(+fg))
=a-b+c*(T-S) where T=/de,S=+fg
=a-b+c*-(TS)
=-ab+c*-(TS)
=-ab+c*V where V=-TS
=X+Y where X=-ab,c*V=Y
=+XY
=+-abc*V
=+-abc*-TS
=+-abc*-/de+fg
| Is This Answer Correct ? | 3 Yes | 16 No |
Explain Array of pointers?
What is meant by linked list?
Is array a data structure?
Which is the parent class of list<e> class?
What is array traversing?
What is data and its type?
What method removes the value from the top of a stack?
When new data are to be inserted into a data structure?
What is a stable sorting algorithm?
Is array a data type?
What is the difference between arrays sort and collections sort?
What is a stable sort?