60分,其余TLE
#include<bits/stdc++.h>
using namespace std;
unsigned long long n,x,t;
unordered_map<unsigned long long,bool> mp;
int main()
{
std::ios::sync_with_stdio(false);
cin>>t;
while(t--)
{
cin>>n;
mp.clear();
for(int i=1;i<=n;i++)
{
cin>>x;
if(mp[x] == 0)
{
cout<<x<<" ";
mp[x] = 1;
}
}
cout<<"\n";
}
return 0;
}