QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#425894 | #7281. How to Avoid Disqualification in 75 Easy Steps | Lynkcat | 15 | 93ms | 25136kb | C++20 | 1.5kb | 2024-05-30 18:36:43 | 2024-05-30 18:36:45 |
Judging History
answer
#include<bits/stdc++.h>
#include "avoid.h"
#define poly vector<int>
#define IOS ios::sync_with_stdio(false)
#define ll long long
#define mp make_pair
#define mt make_tuple
#define pa pair < int,int >
#define fi first
#define se second
#define inf 1e18
#define mod 998244353
#define sz(x) ((int)((x).size()))
// #define int ll
// #define N
using namespace std;
const int d[4]={3,5,7,11};
const int B=55;
mt19937_64 rnd(time(0));
ll val[1005];
pair<int,int> scout(int R, int H)
{
for (int i=1;i<=1000;i++)
{
poly ww(B,0);
for (int j=0;j<B;j++) ww[j]=j;
shuffle(ww.begin(),ww.end(),rnd);
for (int j=0;j<20;j++) val[i]|=(1ll<<ww[j]);
}
unordered_map<ll,int>Mp;
for (int i=1;i<=1000;i++)
for (int j=i;j<=1000;j++)
{
// cout<<i<<" "<<j<<" "<<(val[i]|val[j])<<endl;
assert(!Mp.count(val[i]|val[j]));
Mp[val[i]|val[j]]=1;
}
for (int i=0;i<B;i++)
{
poly now;
for (int j=1;j<=1000;j++)
if ((val[j]>>i)&1) now.push_back(j);
send(now);
}
poly now=wait();
ll res=0;
for (int i=0;i<sz(now);i++)
if (now[i]) res|=(1ll<<i);
for (int i=1;i<=1000;i++)
for (int j=i;j<=1000;j++)
if (res==(val[i]|val[j]))
{
return mp(i,j);
}
}
/*list:
1.mod 998244353 or 1e9+7 or ???
2.N
3.duipai shuju xingtai duoyidian
...
*/
Details
Tip: Click on the bar to expand more detailed information
Subtask #1:
score: 0
Wrong Answer
Test #1:
score: 0
Wrong Answer
time: 58ms
memory: 25136kb
input:
output:
result:
wrong answer Not correct
Subtask #2:
score: 0
Wrong Answer
Test #11:
score: 0
Wrong Answer
time: 53ms
memory: 24900kb
input:
\x14
output:
result:
wrong answer Not correct
Subtask #3:
score: 0
Wrong Answer
Test #66:
score: 0
Wrong Answer
time: 60ms
memory: 24904kb
input:
\x1e
output:
result:
wrong answer Not correct
Subtask #4:
score: 15
Acceptable Answer
Test #120:
score: 15
Acceptable Answer
time: 86ms
memory: 24380kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #121:
score: 15
Acceptable Answer
time: 79ms
memory: 24412kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #122:
score: 15
Acceptable Answer
time: 87ms
memory: 24380kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #123:
score: 15
Acceptable Answer
time: 82ms
memory: 24408kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #124:
score: 15
Acceptable Answer
time: 63ms
memory: 24468kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #125:
score: 15
Acceptable Answer
time: 76ms
memory: 24304kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #126:
score: 15
Acceptable Answer
time: 83ms
memory: 24384kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #127:
score: 15
Acceptable Answer
time: 71ms
memory: 24384kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #128:
score: 15
Acceptable Answer
time: 83ms
memory: 24364kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #129:
score: 15
Acceptable Answer
time: 93ms
memory: 24392kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #130:
score: 15
Acceptable Answer
time: 80ms
memory: 24464kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #131:
score: 15
Acceptable Answer
time: 76ms
memory: 24364kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #132:
score: 15
Acceptable Answer
time: 73ms
memory: 24344kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #133:
score: 15
Acceptable Answer
time: 85ms
memory: 24304kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed
Test #134:
score: 15
Acceptable Answer
time: 78ms
memory: 24456kb
input:
K
output:
result:
points 0.2000000030 points 0.2000000030 Correct: 55 robot(s) used, 1 hour(s) passed