QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#525201#9162. COVID testsANIG0 4529ms3860kbC++14678b2024-08-20 14:32:212024-08-20 14:32:21

Judging History

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

  • [2024-08-20 14:32:21]
  • 评测
  • 测评结果:0
  • 用时:4529ms
  • 内存:3860kb
  • [2024-08-20 14:32:21]
  • 提交

answer

#include <bits/stdc++.h>
using namespace std;
#define int long long
const int N=1005;
int n,t,rs[N];
double k;
int gets(int l,int r){
	cout<<"Q ";
	for(int i=1;i<l;i++)cout<<0;
	for(int i=l;i<=r;i++)cout<<1;
	for(int i=r+1;i<=n;i++)cout<<0;
	cout<<endl;
	int x;
	cin>>x;
	return x;
}
void solve(int l,int r){
	if(l==r){
		rs[l]=1;
		return;
	}
	int mid=l+r>>1;
	if(gets(l,mid)){
		if(gets(mid+1,r))solve(mid+1,r);
		solve(l,mid);
	}else solve(mid+1,r);
}
void find_positive(){
	memset(rs,0,sizeof(rs));
	solve(1,n);
	cout<<"A ";
	for(int i=1;i<=n;i++)cout<<rs[i];
    cout<<endl;
}
signed main(){
	cin>>n>>k>>t;
	while(t--)find_positive();
}

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: 3860kb

input:

1000 0.789673 1
P
P
P
P
P
P
P
P
P
W

output:

Q 1111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111...

result:

points 0.0 0.0 translate:wrong

Subtask #2:

score: 0
Wrong Answer

Test #18:

score: 0
Wrong Answer
time: 4529ms
memory: 3784kb

input:

1000 0.001 300
N
N
N
N
N
N
N
N
N
W

output:

Q 1111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111...

result:

points 0.0 0.0 translate:wrong