#include #include #include #include #include #include #include #include #include #include using namespace std; #define MID(x,y) ((x+y)>>1) #define CLR(arr,val) memset(arr,val,sizeof(arr)) #define FAST_IO ios::sync_with_stdio(false);cin.tie(0); const double PI = acos(-1.0); const int INF = 0x3f3f3f3f; const int N=2e5+7; int a[200001]; int main() { //freopen("f:/input.txt", "r", stdin); int zu,i,j,k,n,len1; int maxx; scanf("%d",&zu); while(zu--) { scanf("%d",&n); for(i=0;is; s.insert(a[0]); for(i=1;i