Drawing and finding the value of postfix expression

3 replies · 2K views · last reply
yakin
Messages
42
Reaction score
0
View attachment 2472
View attachment 2473

I am ending with no operator in the end. So 1000 160 would be the answer or what. I do not know what to do from here. Please help!
 
Attachments
  • Printed exercise: "The postfix form of an expression is:" followed by 3 7 + 3 ↑ 100 60 - 4 ×, with an arrow above the caret symbol, then "Draw the binary tree and give the value of the expression."
    Capture.JPG
    11.5 KB · Views: 147
  • Handwritten evaluation of the postfix expression 3 7 +3 ↑ 100 60 -4 x on lined paper, with step-by-step reductions and two expression trees drawn below, ending in the line 1000 60.
    20140511_213927.jpg
    53.3 KB · Views: 149
yakin said:
https://www.physicsforums.com/attachments/2472
https://www.physicsforums.com/attachments/2473

I am ending with no operator in the end. So 1000 160 would be the answer or what. I do not know what to do from here. Please help!
Yes you end up short one operator, so you have nodes containing 1000 and 160 with no operator to join them.
 
DavidCampen said:
Yes you end up short one operator, so you have nodes containing 1000 and 160 with no operator to join them.
So 1000 and 160 is the answer. And did I draw the Binary Tree right?
 
yakin said:
So 1000 and 160 is the answer. And did I draw the Binary Tree right?

Yes and yes.