# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
850659 |
2023-09-17T08:33:57 Z |
alexdd |
Brperm (RMI20_brperm) |
C++17 |
|
317 ms |
3200 KB |
#include "brperm.h"
#include<bits/stdc++.h>
using namespace std;
int n;
static char s[500005];
int inv(int x, int p)
{
int aux=0;
for(int i=0;i<p;i++)
{
if(((1<<i)&x))
{
aux += (1<<(p-i-1));
}
}
return aux;
}
void init(int N, const char cit[])
{
n=N;
for(int i=0;i<n;i++)
s[i]=cit[i];
return;
}
int query(int i, int k)
{
int lun=(1<<k);
for(int pas=0;pas<500;pas++)
{
int x = rand()%lun;
if(s[i+x]!=s[i+inv(x,k)])
return 0;
}
return 1;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
8 ms |
716 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
8 ms |
716 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Runtime error |
317 ms |
3200 KB |
Execution killed with signal 11 |
2 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Incorrect |
8 ms |
716 KB |
Output isn't correct |
2 |
Halted |
0 ms |
0 KB |
- |