#include <stdio.h>
void main() {
int num;
scanf("%d", &num);
if (num < 10000) {
int temp = num;
int i = 0;
int breaker[] = {1000, 100, 10, 1};
while (i < 4) {
temp = temp % breaker[i];
if (temp != num) {
num -= temp;
printf("%d\n", num);
num = temp;
}
i++;
}
}
}
To embed this project on your website, copy the following code and paste it into your website's HTML: