#include <iostream>using namespace std;void main(){ int n; cout<<\"输入一个整数n,n<9999:\"; cin>>n; char buf[5]={0}; itoa(n,buf,10); for(int i=0;i<strlen(buf);i++) cout<<buf[i]<<\" \"; cout<<endl;}
谢谢!