Question: From an expression tree, how do I write a file that contains the three address format instructions. I am insterested in the java code to

From an expression tree, how do I write a file that contains the three address format instructions. I am insterested in the java code to do this. My program accepts an arithmetic expression of unsigned integers in postfix notation and builds the arithmetic expression tree that represents that expression. From that tree, the corresponding fully parenthesized infix expression is displayed in the GUI. I am trying to take that expression tree and generate a file that contains the three address format instructions for the expression input into the GUI.

The output file should diplay the below:

Add R0 5 9

Sub R1 3 R0

Mul R2 2 3

Div R3 R1 R2

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!