Module: (Java) Loop statement with condition - while


Problem

12 /21


Number vice versa

Problem

Given a natural number N. Get the number obtained by rearranging the digits of the original number in the reverse order. Display the new number and the difference between the original number and the converted

Input: one natural number is entered
Output: In the first line print the number obtained by rearranging the digits of the original number in the reverse order (without insignificant zeros)
In the second line print one number - the difference between the original number and the new number

Example
Input Output
1 2010 102
1908