Separating the digits of given number
Hi everyone,
I am trying to write a program which inputs one number consisting of five digits, then that number is being separated into individual digits separated each by (for example) 5 positions and prints out the newly separated number. For instance, if the user types in 12345 the program displays 1 2 3 4 5.
I am using java.util.Scanner but the tricky part is the separating of the actual digits.
Any ideas are greatly appreciated.
Thanks in advance,
LB
P.S. The number is typed in by the user using Scanner class.