#include #include #define STACK_SIZE 1000 #define SUCCESS 1 #define FAILURE 0 typedef long unsigned int data_t; data_t stack_data[STACK_SIZE]; int stack_num; int push(data_t push_data) { if (stack_num < STACK_SIZE) { stack_data[stack_num] = push_data; stack_num ++; return SUCCESS; } else { return FAILURE; } } int pop(data_t *pop_data) { if (stack_num > 0) { stack_num --; *pop_data = stack_data[stack_num]; return SUCCESS; } else { return FAILURE; } } int main(){ int n = 0; scanf("%d",&n); long unsigned int a = pow(10, n); long double b = sqrt(a); stack_num = 0; for(int i=1; i<=b; i++){ int c = a%i; int c2 = a/i; if(c==0){ if(c2!=i){ push(c2); } printf("%d\n",i); } } long unsigned int tmp; while(pop(&tmp)){ printf("%lu\n",tmp); } }