#include <bits/stdc++.h>
using namespace std;
const int N = 5e3 + 9;
const int M = 5e4 + 9;
long long read() {
  long long x = 0, op = 1;
  char c = getchar();
  while (!isdigit(c)) {
    if (c == '-') op = -1;
    c = getchar();
  }
  while (isdigit(c)) x = x * 10 + c - 48, c = getchar();
  return x * op;
}
signed main() {
  int T = read();
  while (T--) {
    int n = read();
    if (n & 1) n--;
    cout << n / 2 + 1 << '\n';
  }
  return 0;
}
