QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#120481#3273. Datalabzhouhuanyi10 531ms3904kbC++11461b2023-07-06 19:07:322023-07-06 19:07:33

Judging History

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

  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2023-07-06 19:07:33]
  • 评测
  • 测评结果:10
  • 用时:531ms
  • 内存:3904kb
  • [2023-07-06 19:07:32]
  • 提交

answer

#include"datalab.h"
#include<iostream>
#include<cstdio>
#include<vector>
#define N 8191
using namespace std;
bitset<N+1>A;
bitset<N+1>B;
vector<int>solve(int k,int LIMIT)
{
    bool op;
    vector<int>p(k);
    p[k-2]=-1,p[k-1]=1;
    for (int i=k-3;i>=0;--i)
    {
	op=1;
	for (int j=0;j<=k-1;++j) A[j]=(j==i);
	B=Add(A,A);
	for (int j=0;j<=k-1;++j) op&=(B[j]==(j==i+1));
	if (op) p[i]=p[i+1];
	else p[i]=-p[i+1];
    }
    return p;
}

Details

Tip: Click on the bar to expand more detailed information

Subtask #1:

score: 10
Accepted

Test #1:

score: 10
Accepted
time: 521ms
memory: 3784kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Test #2:

score: 10
Accepted
time: 525ms
memory: 3792kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Test #3:

score: 10
Accepted
time: 521ms
memory: 3896kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Test #4:

score: 10
Accepted
time: 529ms
memory: 3788kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Test #5:

score: 10
Accepted
time: 530ms
memory: 3724kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Test #6:

score: 10
Accepted
time: 530ms
memory: 3792kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Test #7:

score: 10
Accepted
time: 530ms
memory: 3728kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Test #8:

score: 10
Accepted
time: 529ms
memory: 3792kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Test #9:

score: 10
Accepted
time: 531ms
memory: 3848kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Test #10:

score: 10
Accepted
time: 526ms
memory: 3880kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Test #11:

score: 10
Accepted
time: 531ms
memory: 3896kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Test #12:

score: 10
Accepted
time: 529ms
memory: 3904kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Test #13:

score: 10
Accepted
time: 524ms
memory: 3788kb

output:

AC
8190

result:

ok Correct, 8190 queries used

Subtask #2:

score: 0
Wrong Answer

Test #14:

score: 0
Wrong Answer
time: 356ms
memory: 3672kb

output:

WA
Too Many Queries!

result:

wrong answer 

Subtask #3:

score: 0
Wrong Answer

Test #46:

score: 0
Wrong Answer
time: 264ms
memory: 3612kb

output:

WA
Too Many Queries!

result:

wrong answer