The number is 42
Step-by-step explanation:
Let the digits be a and b.
The sum of the digits of a two-digit number is 6
That is
a + b = 6
When the digits are reversed, the number decreases by 18
ab - ba = 18
We need to find the number
Since ab - ba = 18, we know that a is greater than b.
Take a = 4
4 + b = 6
b = 6 - 4 = 2
That is the number is ab = 42
When it is reversed the number is 24.
42 - 24 = 18, hence correct
The number is 42