| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 54737 | 李思贤 | 寻找最低数 | C++ | Accepted | 100 | 1 MS | 260 KB | 470 | 2022-07-29 17:04:07 |
#include<bits/stdc++.h> using namespace std; int a; int niubi[1000010]; int er(int a){ int cnm=1,i=1; while(a>0){ niubi[i]=a%2; a/=2; i++; } for(int j=i;j>=1;j--){ cnm*=10; cnm+=niubi[j]; } for(int j=1;j<=i;j++){ niubi[j]=0; } return cnm; } int di(int a){ int b=1; while(a%10==0){ a/=10; b*=2; } return b; } int main(){ cin>>a; while(a!=0){ int sb=er(a); cout<<di(sb)<<endl; cin>>a; } return 0; }