#include <stdio.h>
int print(int num)//递归实现
{
if (num > 9)
{
print(num / 10);
}
printf("%d\t", num % 10);
}
int main()
{
int num = 0;
printf("请输入一个整数:");
scanf_s("%d", &num);
print(num);
system("pause");
return 0;
}
#include <stdio.h>
int print(int num)//递归实现
{
if (num > 9)
{
print(num / 10);
}
printf("%d\t", num % 10);
}
int main()
{
int num = 0;
printf("请输入一个整数:");
scanf_s("%d", &num);
print(num);
system("pause");
return 0;
}