ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#210932 | #2067. 肉夹馍 | 18915523188 | 0 | 0ms | 1232kb | C++ | 376b | 2024-08-08 11:41:31 | 2024-08-08 14:28:59 |
answer
#include <bits/stdc++.h>
#define ll long long
using namespace std;
ll n,an[2000006],l,k;
char s[2000006];
int main()
{
ios_base::sync_with_stdio(false);
cin>>s;
l=strlen(s);
an[0]=1;
for(int i=1;i<=l;i++){
k=an[i-1];
if(s[k]=s[i+k]){
an[i]=an[i-1]+1;
}else{
an[i]=1;
}
cout<<an[i]<<" ";
}
return 0;
}
Details
小提示:点击横条可展开更详细的信息
Subtask #1:
score: 0
Wrong Answer
Test #1:
score: 0
Wrong Answer
time: 0ms
memory: 1232kb
input:
qpbvqpbvqpbvavdqpbvqpbvqpbvavdqpbvqpbvqpbvavdfnfninqpbvqpbvqpbvavdqpbvqpbvqpbvavdqpbvqpbvqpbvavd
output:
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 ...
result:
wrong answer 1st words differ - expected: '0', found: '2'
Subtask #2:
score: 0
Skipped
Subtask #3:
score: 0
Skipped
Subtask #4:
score: 0
Skipped