Question
Write a program using MIPS (MARS Simulator) assembly language to divide an unsigned integer x, by another unsigned integer y, and produce a quotient and
Write a program using MIPS (MARS Simulator) assembly language to divide an unsigned integer x, by another unsigned integer y, and produce a quotient and a remainder.
Use repeated subtraction to carry out the division. The algorithm is trivial, and does not need much explaination. If x = 25 and y = 9 then you can subtract 9 at most twice from 25 (quotient will be 2) and the remainder after the subtraction will be 7.
The user should be able to enter a number between 0 and 255 after the prompts "Enter x" and "Enter y" are displayed on the screen. The results will be displayed on the screen as "Quotient=" and Remainder="
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started