Added a few instructions to save $ra to the stack. Fixes an infinite looping issue. Algorithm is 100% done now.