#include <bits/stdc++.h>
using namespace std;
int t, n, a[1005];
int main() {
  scanf("%d", &t);
  while (t--) {
    scanf("%d", &n);
    int q = 1;
    for (int i = 1; i <= n; i++) {
      scanf("%d", a + i);
      if (q)
        for (int j = 1; j < i; j++)
          if (a[i] == a[j]) {
            j = i;
            q = 0;
          }
    }
    if (q)
      printf("NO\n");
    else
      printf("YES\n");
  }
}
