Count digits in original number
original_no = n ; NEW_LINE sumDigits = 0 ; NEW_LINE while ( original_no > 0 ) : NEW_LINE INDENT sumDigits += 1 ; NEW_LINE original_no = int ( original_no / 10 ) ; NEW_LINE DEDENT