### My issue

### My code

```
#include <iostream>
#include<bits/stdc++.h>
using namespace std;
#define ll long long
int main() {
ll int t;
cin>>t;
while(t--){
ll n;
cin>>n;
ll count = 0;
ll a[n];
for(int i=0; i<n; i++){
cin>>a[i];
}
sort(a , a+n);
for(int i=0; i<n; i++){
if(a[i] == a[i+1]){
count++;
}
}
if(count == 0){
cout<<n<<endl;
}
else if(count == (n-1)){
cout<<"1"<<endl;
}
else{
cout<<(count+ (n - count) - 1)<<endl;
}
}
return 0;
}
```

Problem Link: CFRTEST Problem - CodeChef