백준 2577 숫자의 개수
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
// TODO Auto-generated method stub
Scanner sc = new Scanner(System.in);
int n = (sc.nextInt() * sc.nextInt() * sc.nextInt());
String str = Integer.toString(n);
for (int i = 0; i < 10; i++) {
int count = 0;
for (int j = 0; j < str.length(); j++) {
if ((str.charAt(j) - '0') == i) {
count++;
}
}
System.out.println(count);
}
}
}