Question: For the project, you will implement a LC - 3 assembly program that implements the basic arithmetic operations, Add, and Subtract, and displays the results

For the project, you will implement a LC-3 assembly program that implements the basic arithmetic operations, Add, and Subtract, and displays the results of these operations. The operands for these operations are single digit numbers. The result of addition should also be single digit.
When invoked the program will prompt for the two operands, perform the operations, display the results and exit, as shown by the following displays.
Each student will work on the project individually. Please do not seek help from others or use code that you may find on the Internet! If you have any questions, please get in touch with me.
Display of Program Output on the Console
LC-3 assembly programming
Program to implement the basic
Arithmetic operations
Enter the first operand:4
Enter the second operand:2
Addition result =6
Subtraction result =2
Exiting.
Extra Credit (10 points)
Display Minus sign if result is negative.
LC-3 assembly programming
Program to implement the basic
Arithmetic operations
Enter the first operand:3
Enter the second operand:5
Addition result =8
Subtraction result =-2
Exiting.
What to submit on Brightspace:
1. The assembly code (.asm file)
2. A screen shot of the console output for each test case.
3. Post these deliverables on Brightspace.
The program will be graded on:
1. Program executes and produces correct results.
2. Display format as shown
3. Follows standards - Use of Registers R0, R1, and R2.
R0 for input and output.
Operand 1 in R1 and Operand 2 in R2.
Appropriate documentation

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 Programming Questions!