QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#20184#2351. Lost in Transferqingyu_orz0 0ms0kbC++20936b2022-02-14 22:27:452023-01-17 09:27:21

Judging History

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

  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2023-01-17 09:27:21]
  • 评测
  • 测评结果:0
  • 用时:0ms
  • 内存:0kb
  • [2022-02-14 22:27:45]
  • 提交

answer

#include<bits/stdc++.h>
#define A 20
using namespace std;
int a[105],b[105];
int p[512][A+1];
int main(){
	mt19937 mt(20051115);
	for(int i=0;i<512;++i){
		for(int j=1;j<=A;++j)p[i][j]=j;
		shuffle(p[i]+1,p[i]+A+1,mt);
	}
	string ss;
	cin>>ss;
	if(ss=="transmit"){
		int T;
		cin>>T;
		while(T--){
			int n;
			cin>>n;
			for(int i=1;i<=n;++i)scanf("%d",&a[i]);
			sort(a+1,a+n+1);
			int yh=0;
			for(int i=1;i<=n;++i)yh^=a[i];
			for(int i=1;i<=A;++i)b[p[yh][i]]=a[i];
			for(int i=A+1;i<=n;++i)b[i]=a[i];
			for(int i=1;i<=n;++i){
				printf("%d",a[i]);
				if(i==n)printf("\n");
				else printf(" ");
			}
		}
	}else{
		int T;
		cin>>T;
		while(T--){
			int n;
			cin>>n;
			for(int i=1;i<=n;++i)scanf("%d",&a[i]);
			int hy=-1;
			for(int yh=0;yh<512;++yh){
				for(int i=1;i<=A;++i){
					for(int j=1;j<=A;++j){
						
					}
				}
			}
			if(hy==-1)assert(0);
		}
	}
	return 0;
}

详细

Test #1:

score: 0
Programme Dangerous Syscalls

input:

transmit
2
20 97 388 459 467 32 99 98 296 403 325 330 271 87 333 378 267 405 58 426 374
20 125 481 451 150 495 136 444 192 118 26 68 281 120 61 494 339 86 292 100 32

output:

32 58 87 97 98 99 267 271 296 325 330 333 374 378 388 403 405 426 459 467
26 32 61 68 86 100 118 120 125 136 150 192 281 292 339 444 451 481 494 495

input:


output:


result: