Cod sursa(job #1822886)

Utilizator TimitocArdelean Andrei Timotei Timitoc Data 5 decembrie 2016 18:40:10
Problema Congr Scor 0
Compilator cpp Status done
Runda Arhiva de probleme Marime 0.7 kb
#include <iostream>
#include <cstdio>
#include <cstdlib>
#include <ctime>
#define MAXN 600010

using namespace std;

int n, p;
int a[MAXN], b[MAXN];

int main()
{
	freopen("congr.in", "r", stdin);
	freopen("congr.out", "w", stdout);

//	srand(time(0));
//    scanf("%d", &n);
//    long long sum = 0;
//    for (int i = 1, k = 2*n-1; i <= k; i++) {
//		int x;
//		scanf("%d", &x);
//		if (i <= n) {
//			a[i] = x;
//			sum += x;
//		}
//        else
//			b[i-n] = x;
//    }
//    while (sum % n) {
//        int i = rand() % n + 1;
//        int j = rand() % (n-1) + 1;
//        sum = sum - a[i] + b[j];
//        swap(a[i], b[j]);
//    }
//	for (int i = 1; i <= n; i++)
//		printf("%d ", a[i]);

	return 0;
}