if string violates tidy property , then decrease the value stored at that index by 1 and replace all the value stored right to that index by 9
str [ i ] -= 1 NEW_LINE for j in range ( i + 1 , len ) : NEW_LINE INDENT str [ j ] = 9 NEW_LINE DEDENT return str NEW_LINE