听灌佬多
  • 板块灌水区
  • 楼主yzx_yzx
  • 当前回复1
  • 已保存回复1
  • 发布时间2024/10/5 11:08
  • 上次更新2024/10/5 13:55:10
查看原帖
听灌佬多
766148
yzx_yzx楼主2024/10/5 11:08

P4305

#include <bits/stdc++.h>
using namespace std;
#define int long long
const int mod = 10007, MOD = 10009;
int T, n, d, a1[12340567], a2[12304567];

signed main() {
	ios::sync_with_stdio(0);
	cin.tie(0);
	cout.tie(0);
	cin >> T;
	for (int i = 1; i <= T; i++) {
		cin >> n;
		for (int j = 1; j <= n; j++) {
			cin >> d;
			if (a1[d % mod] != i || a2[d % MOD] != i) {
				a1[d % mod] = i;
				a2[d % MOD] = i;
				cout << d << " ";
			}
		}
		cout << endl;
	}
	return 0;
}
2024/10/5 11:08
加载中...