Home / Expert Answers / Computer Science / 1-write-the-following-code-segment-in-marie-assembly-language-2-reference-marie-examples-to-assis-pa325

(Solved): 1. Write the following code segment in MARIE assembly language 2. Reference MARIE examples to assis ...




1. Write the following code segment in MARIE assembly language
2. Reference MARIE examples to assist in writing the source co
Test case
M MARIE Simulator
Machine hated normaly.
1. Write the following code segment in MARIE assembly language 2. Reference MARIE examples to assist in writing the source code 3. Comments MUST be included for EVERY line. No comments result in ONLY \( 50 \% \) of total grading rubric value. \[ \begin{array}{l} \text { Sum : }=0 \\ \text { for } X:=1 \text { to } 10 \text { do } \\ \text { Sum }:=\text { Sum }+X ; \end{array} \] Task (use as comments) / Load program in memory / Load constant / Initialize loop control variable \( X \) / Loop label, Load X / Compare \( \mathrm{X} \) to 10 If \( \mathrm{AC}<0 \) ( \( \mathrm{X} \) is less than 10), continue loop I If \( \mathrm{X} \) is not less than 10 , terminate loop / Load Sum / Add \( \mathrm{X} \) to Sum / Store result in Sum / Load X / Increment \( \mathrm{X} \) Store X / Jump back to top of loop / Label Endloop to Jump to, Load Sum / Print Sum / Terminate program / Storage for Sum / Storage for \( \mathrm{X} \) / The constant value 1 /The loop constant / Stop Assembly Source compiles with no errors Source compiles with no warnings Source runs with no errors Test case M MARIE Simulator Machine hated normaly.


We have an Answer from Expert

View Expert Answer

Expert Answer


Below find the solution Load program in memory Load Sum // Load constant Load 1 // Initialize loop control va
We have an Answer from Expert

Buy This Answer $5

Place Order

We Provide Services Across The Globe