Write a MARIE assembly code to perform the following pseudocode excerpt. Input a number Assign this number to x Input a number Assign this number to y If y< x { Let z= 2*x } Assign the value of y to AC Else { Let z=3*x Assign the value of x to AC } End: Display the AC value. Stop b) Include a screenshot of the simulation's result (A screenshot of the MARIE Simulator window after running the program). Instructions: - Use "ORG" instruction to start your program at address equivalent to (30008). - use the number 5 as the value of x and 9 as the value of y. - Do not forget to change the Input and output boxes to decimal! - Proper labels and directives should be included at the end of your program.

icon
Related questions
Question
Write a MARIE assembly code to perform the following
pseudocode excerpt.
Input a number
Assign this number to x
Input a number
Assign this number to y
If y< x
{
Let z= 2*x
}
Assign the value of y to AC
Else
{
Let z=3*x
Assign the value of x to AC
}
End: Display the AC value
Stop
b) Include a screenshot of the simulation's result (A
screenshot of the MARIE Simulator window after running
the program).
Instructions:
- Use "ORG" instruction to start your program at address
equivalent to (30008).
- use the number 5 as the value of x and 9 as the value
of y.
- Do not forget to change the Input and output boxes to
decimal!
- Proper labels and directives should be included at the
end of your program.
Transcribed Image Text:Write a MARIE assembly code to perform the following pseudocode excerpt. Input a number Assign this number to x Input a number Assign this number to y If y< x { Let z= 2*x } Assign the value of y to AC Else { Let z=3*x Assign the value of x to AC } End: Display the AC value Stop b) Include a screenshot of the simulation's result (A screenshot of the MARIE Simulator window after running the program). Instructions: - Use "ORG" instruction to start your program at address equivalent to (30008). - use the number 5 as the value of x and 9 as the value of y. - Do not forget to change the Input and output boxes to decimal! - Proper labels and directives should be included at the end of your program.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 4 steps

Blurred answer