#include <bits/stdc++.h>
using namespace std;
signed main() {
  long long t, n;
  cin >> t;
  while (t--) {
    cin >> n;
    std::vector<long long> a(n);
    long long cur = 0, ans = 1;
    for (long long i = 0; i < n; i++) cin >> a[i];
    sort(a.begin(), a.end());
    for (long long i = 0; i < n; i++) {
      if (ans + cur < a[i])
        cur++;
      else
        ans += cur + 1, cur = 0;
    }
    std::cout << ans << std::endl;
  }
  return 0;
}
