Hi. I'm supposed to reverse a number based on user input. Example, if the user inputs 123, the output should be 321. However, so far, the way it is now, if the user inputs 123, the output is 312. I'm a little lost -_- help please.
while ( input != 0 ) {
int num1 = input % 10
int num2 = input / 10;
//Display results
JOptionPane.showMessageDialog(null, "Reverse of " + input + " is " + num1 + num2);
break;
}