Fixed registerArithmetic method so that typing something like 1+1+1=3 and not 2 like before.