Loop to iterate over the digits of the number N
while ( n != 0 ) : NEW_LINE INDENT r = n % b NEW_LINE n = n // b NEW_LINE if r in m : NEW_LINE INDENT m [ r ] += 1 NEW_LINE DEDENT else : NEW_LINE INDENT m [ r ] = 1 NEW_LINE DEDENT DEDENT last = - 1 NEW_LINE