| Run ID | Author | Problem | Lang | Verdict | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|
| 41755 | Songgr | 1的个数 | C++ | Compile Error | 0 MS | 0 KB | 217 | 2024-02-23 10:17:01 |
#include<bits/stdc++.h> using namespace std; int mian() { int n,cnt=1;; cin>>n; for(int i=10;i<=n;i++){ int m=i; while(m){ if(m%10==1) cnt++; m/=10; } } cout<<cnt; return 0; }