how to get separate digits of a list java code example
Example: how to separate a number into digits java
public static void main(String[] args) {
int num=1020; // int number
while (num > 0) {
System.out.println( num % 10);
num = num / 10;
}
}