An integer two-digit number is given.
Input example
79
Sample output
9 7
I do not understand, then you need to work with strings? Simple theme Numbers
An integer two-digit number is given.
Input example
79
Sample output
9 7
I do not understand, then you need to work with strings? Simple theme Numbers
It seems that this question does not correspond to the subject of the site. Those who voted to close it indicated the following reason:
Apparently, something is expected from you like this:
both = int(input('Введите двухзначное число')) left = both // 10 right = both - (left*10) print('%s %s' % (right, left)) I don’t know only whether the integer division can be considered an “arithmetic operator”. But, in which case, it can be replaced by int(both/10)
right = both - (left*10) : right = both % 10 - gil9red tens, units = number // 10, number % 10 # The same as divmod(number, 10) print(units, tens) Source: https://ru.stackoverflow.com/questions/913131/
All Articles
правитьbutton) - it will be easier for you to help with it :) - gil9red