- Write a method, reverseDigits that takes an integer as parameter and returns the number with the digits reversed. Also, write a program to test your function.
Here is a sample of input/output:
Enter an integer: 4567
4567 after digits reversed = 7654
Enter an integer: -45
-45 after digits reversed = -54
Enter an integer: 980
980 after digits reversed = 89