#include<bits/stdc++.h>

using namespace std;

set < pair <int,int> > sm;
set <int> uniq;

char in[] = "?.in", out[] = "?.out";

int main() {
	
	srand(NULL);
	
	for(int i = 0; i < 10; ++i) {
		
		in[0] = i + '0';
		freopen(in, "w", stdout);
		
		int n = rand() * rand() % 400000 + 1,
		m = rand() % 1000 + 7, v = rand() * rand() % 20000000 + 1;
		
		printf("%d\n",n);
		
		for(int i = 0; i < m; ++i) {
			
			int x = v - 15 * rand();
			
			if(x < 0 || sm.find(x) != sm.end()) {
				
				--i;
				
				continue;
			}
			
			sm.insert({x, v - x});
		}
		
		for(int i = 0; i < n; ++i) {
			
			if(i == n / 2) {
				
				for(auto)
				
				--i;
			}
			
			int u = rand() * rand() % 1000000;
			
			if(uniq.find(u) != uniq.end()) {
				
				--i;
				
				continue;
			}
			
			printf("%d ",u);
			
			uniq.insert(u);
		}
	}
}

1 comments

  • @ 2024-11-25 20:28:39

    这个是我没写完的代码 没有价值 别看 我为了保存才上传到这里的

    • 1