Reputation: 71
I am learning assembly code and am trying to write a function for assembly code that finds the modulus of two numbers. The pseudocode for this problem would be just fine.
Upvotes: 0
Views: 274
Reputation: 15501
You could try repeated subtraction.
modulus(a, b)
while a >= b
a -= b
return a
Upvotes: 1