Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
2352 | 邓小龙 | 15几个数字组成 | C++ | Accepted | 0 MS | 260 KB | 292 | 2023-12-23 18:56:10 |
#include<iostream> #include<cmath> using namespace std; int main() { int a,b=0; cin>>a; if(a==0) cout<<1; else { a=abs(a); while(a>0) { a/=10; b++; } cout<<b; } return 0; }