| Run ID | 作者 | 问题 | 语言 | 测评结果 | 时间 | 内存 | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 74601 | sh25_shenpy | 数字反转 | C++ | 解答错误 | 0 MS | 252 KB | 425 | 2025-11-29 22:05:41 |
#include <bits/stdc++.h> using namespace std; int main( ) { int n,w,x,y; cin>>n; if(n%10>0){ cout<<n%10; } for(int u=1;u<=10;u++){ x=pow(10,u); if(n<x&n>-x){ y=u; break; } } for(int i=1;i<y;i++){ x=pow(10,i); w=n%x; if(((n-w)/x)%10>0){ cout<<((n-w)/x)%10; } } return 0; }