public class Main {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int number = scanner.nextInt();
int[] res = new int[10];
scanner.close();
for (int i = 1; i <= number; i++) {
String str = Integer.toString(i);
char[] n = str.toCharArray();
for (int j = 0; j < n.length; j++) {
System.out.print(n[j]);
int var = n[j];
res[var]++;
}
}
for (int i : res) {
System.out.print(i + " ");
}
}
}