Submission #642668

#TimeUsernameProblemLanguageResultExecution timeMemory
642668TimDeeBrperm (RMI20_brperm)C++17
0 / 100
4 ms1380 KiB
#include "brperm.h" #include <bits/stdc++.h> using namespace std; const char *S; void init(int n, const char s[]) { S=s; return; } int query(int ind, int k) { for (int i=ind; i<ind+(1<<k); ++i) { int j=0; for (int b=k-1; b>=0; --b) { j+=(((i-ind)>>b)&1)<<(k-1-b); } if (S[i]!=S[ind+j]) return 0; } return 1; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...