QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#221008#148. BrpermAhmed57#0 0ms17888kbC++23627b2023-10-21 01:55:582024-07-04 02:21:06

Judging History

你现在查看的是最新测评结果

  • [2024-07-04 02:21:06]
  • 评测
  • 测评结果:0
  • 用时:0ms
  • 内存:17888kb
  • [2023-10-21 01:55:58]
  • 提交

answer

#include<bits/stdc++.h>
using namespace std;
#include "brperm.h"

string str;int lol[20][500001];
void init(int n, const char s[]){
    for(int i = 0;i<n;i++){
        str+=s[i];
    }
    for(int k = 0;(1<<k)<=n;k++){
        for(int i = 0;i<(1<<k);i++){
            lol[k][i] = 0;
            for(int j = 0;j<k;j++){
                if(i&(1<<j)){
                    lol[k][i]|=(1<<(k-j-1));
                }
            }
        }
    }
}
int query(int i , int k){
    for(int l = i;l<i+(1<<k);l++){
        if(str[l]!=str[lol[k][l-i]+i]){
            return 0;
        }
    }
    return 1;
}

Details

Tip: Click on the bar to expand more detailed information

Subtask #1:

score: 0
Wrong Answer

Test #1:

score: 0
Wrong Answer
time: 0ms
memory: 17888kb

input:

ykkubxafnylfriivjjqphltuagfkfcoigfcukuisdgufezomndodalbusgesraatkgnskdsiedfysodmsemmtjuoiezoaqljdodegogedjfpfwntljpgdhswtmqtwtpnbaawfumskuiwjodtsrlhblpunzqjkrzaakamjzyumkzfdjxwdkadgbwffjmldsfbhaltfnykbmvnxdkpfzsswpnmyyqpalsalaeqmqqivzqyhjgiiwfugmpxxsmkkgecuvrnlkujbyllhecpjsneluvsyckueeexhbtuhikfzuvw...

output:

0
1
0
1
1
0
1
1
1
0
0
1
1
0
0
1
0
0
0
1
0
1
1
1
1
0
1
0
0
0
1
0
0
1
1
1
1
1
1
1
1
1
0
0
0
0
0
0
1
1
0
0
1
1
1
0
0
1
0
1
1
1
1
0
0
1
0
0
0
1
1
1
1
1
1
0
1
0
0
1
1
1
1
0
1
0
0
0
1
0
0
0
0
0
1
1
1
1
1
0
0
0
0
0
0
1
0
1
0
0
0
0
0
1
1
0
1
0
0
0
1
0
0
0
0
1
1
0
0
0
0
1
1
1
0
1
1
0
0
0
0
1
0
0
1
1
1
1
1
0
...

result:

wrong answer 602nd lines differ - expected: '0', found: '1'

Subtask #2:

score: 0
Skipped

Dependency #1:

0%

Subtask #3:

score: 0
Time Limit Exceeded

Test #6:

score: 0
Time Limit Exceeded

input:

bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb...

output:

0
0
1
0
0
1
0
0
0
1
0
0
0
1
1
1
0
0
1
1
1
1
1
1
0
0
1
1
0
1
1
0
0
0
0
1
1
0
1
0
1
1
1
0
0
1
1
0
1
1
0
0
1
0
1
0
1
0
1
1
1
1
1
0
0
1
1
1
1
0
0
0
1
0
1
0
0
0
1
1
1
1
1
0
0
1
1
0
0
0
1
1
0
1
1
1
1
0
1
0
1
0
0
1
1
0
1
0
0
1
1
0
1
0
1
1
0
1
0
0
0
1
1
1
1
1
0
0
0
0
1
0
0
0
0
1
0
0
0
0
1
0
1
1
0
1
1
1
1
0
...

result:


Subtask #4:

score: 0
Skipped

Dependency #1:

0%