If the last digit of dequeued integer is not 9 , then enqueue the next such number .
if ( arr [ i ] % 10 != 9 ) : NEW_LINE INDENT q . append ( arr [ i ] * 10 + arr [ i ] % 10 + 1 ) NEW_LINE DEDENT print ( arr [ N ] ) NEW_LINE