QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#642655 | #5434. Binary Substrings | guodong# | WA | 0ms | 3536kb | C++17 | 405b | 2024-10-15 15:32:30 | 2024-10-15 15:32:30 |
Judging History
answer
#include <bits/stdc++.h>
#define For(i,a,b) for(int i = a; i <= b; ++i)
using namespace std;
signed main(){
#ifdef NICEGUODONG
freopen("data.in","r",stdin);
#endif
int n;
cin >> n;
int len = 1;
string a;
while(1){
For(i,1,len){
a.push_back('0');
}
For(i,1,len){
a.push_back('1');
}
++len;
if(a.size() > n)
break;
}
For(i,0, n - 1)
cout << a[i];
}
詳細信息
Test #1:
score: 100
Accepted
time: 0ms
memory: 3508kb
input:
2
output:
01
result:
ok meet maximum 3
Test #2:
score: -100
Wrong Answer
time: 0ms
memory: 3536kb
input:
5
output:
01001
result:
wrong answer not meet maximum 11 < 12