#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
void Y() { cout << "YES\n"; }
void N() { cout << "NO\n"; }
int n, in[10005];
int main() {
  ios::sync_with_stdio(0), cin.tie(0);
  int t;
  cin >> t;
  while (t--) {
    cin >> n;
    for (int i = 0; i < n; ++i) cin >> in[i];
    bool bad = true;
    for (int i = 0; i < n; ++i) {
      for (int j = i + 1; j < n; ++j) {
        if (in[i] == in[j]) bad = false;
      }
    }
    if (bad)
      N();
    else
      Y();
  }
  return 0;
}
