Question: Below code performs the division operation (B-A)/A using only addition and/or subtraction operations. Let A is stored in $t0 and B in $t1 registers respectively

 Below code performs the division operation (B-A)/A using only addition and/or

Below code performs the division operation (B-A)/A using only addition and/or subtraction operations. Let A is stored in $t0 and B in $t1 registers respectively through user input at runtime and B is always greater than A. Output prints out the remainder of division operation. Please fill in the blanks: .text li $t2,0 sub $t1,$t1, to div_loop: #loop name blt exit sub $t1, move $t3, $t1 addi $t2, $t2, 1 j div_loop exit:li $v0, 1 move $ao, syscall li $v0, 10 syscall

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!