| 比赛 | 初一开训小练习 | 评测结果 | AAAAAAAAAA |
|---|---|---|---|
| 题目名称 | 01数字 | 最终得分 | 100 |
| 用户昵称 | 无 | 运行时间 | 0.029 s |
| 代码语言 | C++ | 内存使用 | 3.69 MiB |
| 提交时间 | 2026-03-10 19:25:26 | ||
#include <bits/stdc++.h>
using namespace std;
int a,b,e;
bool c=true;
int main(){
freopen("torch.in","r",stdin);
freopen("torch.out","w",stdout);
cin>>a;
for(int i=1;i<=30000;i++){
e=a*i;
while(e>0){
if(e%10!=1&&e%10!=0){
c=false;
break;
}
else{
e/=10;
}
}
if(c){
cout<<i;
return 0;
}
c=true;
}
cout<<"NO";
}