求助0pts
查看原帖
求助0pts
1076621
Xiaonao_Dali楼主2023/12/27 22:12
#include<cstdio>
using namespace std;
int main(){
    int  a[20000005]={0}, x,xxs;
    scanf("%d", &xxs);
    for(int i = 0; i < xxs; i++){
        int n;
        scanf("%d", &n);
        for(int j = 0; j < n; j++){
            scanf("%d", &x);
            if(a[x] == 0){
                printf("%d ", x);
            }
            a[x] = 1;
        } 
        printf("\n");
    }   
    return 0;
}
2023/12/27 22:12
加载中...