#include <stdio.h>

int main(){
int i,j,count,pomi;
for(i=0; i<10000; i++){
    pomi = i;
    for(count = 0; pomi!=0; pomi/=10)
        count++;
    for(j=0;j<(4-count);j++)
        printf("0");
    if(i!=0)
        printf("%d",i);
    printf("\n");
}
return 0;
}

