1 Replies - 1818 Views - Last Post: 17 April 2013 - 03:24 PM

Factorial Infinite Loop Problem (MIPS)

Posted 17 April 2013 - 03:22 PM

Hello,

I have been tasked with writing a simlple calculator, and one of the functions it must complete is to compute the binomial coefficient (nchoosek) of two numbers. I have posted (hopefully) all relevant code that I have written so far. My problem is that the 'factorial' function seems to endlessly loop and I cannot for the life of me figure out why!

My end goal is to be able to save the result of the calculation of the binomial coefficient into register $s0. Any help would be greatly appreciated!