# Recent questions tagged infix-prefix 1
Assume that the operators $+,-,\times$ are left associative and $\wedge$ is right associative. The order of precedence(from highest to lowest) is $\wedge,\times, +,-$. The postfix expression corresponding to the infix expression $a+b\times c-d\wedge e\wedge f$ is $abc\times+def\wedge\wedge-$ $abc\times+de\wedge f\wedge-$ $ab+c\times d-e\wedge f\wedge$ $-+a\times bc\wedge\wedge def$
2
Convert the pre-fix expression to in-fix $- ^{\ast} +ABC^{\ast} – DE+FG$ $(A-B)^{\ast}C+(D^{\ast}E)-(F+G)$ $(A+B)^{\ast}C-(D-E)^{\ast}(F-G)$ $(A+B-C)^{\ast}(D-E)^{\ast}(F+G)$ $(A+B)^{\ast}C-(D^{\ast}E)-(F+G)$
3
Consider the new-order strategy for traversing a binary tree: Visit the root Visit the right subtree using new-order Visit the left subtree using new-order The new-order traversal of expression tree corresponding to the reverse polish expression 3 4 * 5 – 2 ^ 6 7 * 1 + – What will be expression, any procedure for it??
1 vote
4
I THING THERE IS MISTAKE BECAUSE BRACKET ARE CLOSING AFTER ELEMENT E SO ALL OPERATORS HOULD BE POPED AND AND ACCORDING TO ME ANWER SHOLD BE 2… TRY AND CORRECT IF I M WRONG !!!! THANKS IN ADVANCE!!!
1 vote
5
My doubt : What should we consider ^ operator as Bitwise XOR ? or Exponentiation
6
Please convert it to postfix by using stack and explain in detail void (*bsd_signal(int sig, void (*func)(int)))(int);
7
HOW TO SOLVE THIS?
8
9
10
Let The value of below expression is A. 6 2 3 + - 3 8 2 / + * 3 ^ 3 + and Let the value of below expression is Y: 2 A * 16 + What is value of sqrt(Y) Ans. 16
11
What is time and space complexity to evaluate postfix expression ?
12
Result for evaluating the following post fix 105+606/*8- I'm confused whether it is correct postfix expression.
1 vote
13
How is ans 15 for this question Please can anybody solve this
14
Choose the equivalent prefix form of the following expression (a+(b-c))*((d-e)/(f+g-h)) *+a-bc/-de-+fgh *+a-bc-/de-+fgh *+a-bc/-ed-+fgh *+ab-c/-de-+fgh
1 vote
15
What we can do if the unary operator comes in infix notation while converting it into postfix/prefix notations? For example, this $a = -b+c*d/e+f↑g↑h-i*j$
16
1. Is postorder same as Reverse polish notation(Postfix)? 2. Is inorder same as polish notation(infix)?
17
Provide short answers to the following questions: Compute the postfix equivalent of the following infix arithmetic expression $a + b * c + d * e ↑ f$ where $↑$ represents exponentiation. Assume normal operator precedences.
18
Time required to evaluate a. prefix, b. infix, c. postfix_____O(n) ? for expression evaluation (infix, prefix, postfix) operand stack needed____True? for conversion from one to another notation operator stack needed_____True? time required for conversion from infix to postfix___O(n) ... among { infix, prefix, postfix } require more scan__? PS: i googled for all this but not found anthing exact..
1 vote
19
Conver the following infix to Postfix and Prefix $log ( 3 ! )^ {log4} *log log ((6/7)*4+x)!$ $sin 2x cos (3x+4)$ Please use stack method to solve . Diagram would be appreciated
20
Given the following prefix expression : $^{*} + 3 + 3 ↑ 3 + 3 3 3$ What is the value of the prefix expression ? $2178$ $2199$ $2205$ $2232$
1 vote
21
The postfix expression AB + CD -* can be evaluated using a stack tree queue linked list
1 vote
22
Consider the following expression with infix notation A * B - (C + D) * (E / 5) ^ F What is the maximum height of the operator stack during conversion from infix to postfix ? a) 3 b) 4 c) 5 d) 6
The following post-fix expression with single digit operands is evaluated using stack, $16\;2\;4\;\wedge \; / \;4\;3\;*\;+\;6\;2\;*\;-$ Note that $\wedge$ is the exponential operator. What is the maximum height of the stack and the final value of post-fix evaluation respectively are a. $3,\;1$ b. $4,\;1$ c. $3,\;12$ d. $2,\;1$
Compute the post fix equivalent of the following expression $3^*\log(x+1)-\frac{a}{2}$