Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
26872 | 唐心 | 输出字符 | C++ | Accepted | 1 MS | 724 KB | 398 | 2022-05-24 17:19:03 |
#include<iostream> #include<cmath> #include<cstdio> #include<cstring> using namespace std; void fun(int n) { int str[100]={0}; int i=0,j; while(n) { str[i] = n%10; n = n/10; i++; } for(j = i-1;j>=0;j--) cout<<str[j]<<" "; } int main() //主函数入口 { int n; cin>>n; fun(n); cout<<endl; return 0; //结束整个程序 }