Drawing and finding the value of postfix expression

Click For Summary
SUMMARY

The discussion centers on evaluating a postfix expression where the user ends up with two operands, 1000 and 160, but lacks an operator to combine them. Participants confirm that without an operator, the result remains as two separate values. Additionally, the user seeks validation on their Binary Tree representation, which is affirmed by other contributors. The conclusion is that the final output is indeed 1000 and 160, with no further operations possible.

PREREQUISITES
  • Understanding of postfix notation and its evaluation
  • Familiarity with Binary Trees and their representation
  • Basic knowledge of operators and operands in expressions
  • Concept of node structure in data representation
NEXT STEPS
  • Study the evaluation process of postfix expressions in detail
  • Learn about Binary Tree construction and traversal methods
  • Explore common operators used in postfix expressions
  • Investigate error handling in expression evaluation scenarios
USEFUL FOR

Students, computer science enthusiasts, and anyone interested in understanding postfix expression evaluation and Binary Tree structures.

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

  • Capture.JPG
    Capture.JPG
    11.5 KB · Views: 114
  • 20140511_213927.jpg
    20140511_213927.jpg
    53.3 KB · Views: 116
Physics news on Phys.org
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.
 

Similar threads

  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 25 ·
Replies
25
Views
2K
  • · Replies 16 ·
Replies
16
Views
2K
  • · Replies 18 ·
Replies
18
Views
3K
  • · Replies 8 ·
Replies
8
Views
2K
  • · Replies 6 ·
Replies
6
Views
2K
  • · Replies 8 ·
Replies
8
Views
2K
  • · Replies 2 ·
Replies
2
Views
1K