#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  long long int tc;
  cin >> tc;
  while (tc--) {
    long long int n1;
    cin >> n1;
    if (n1 == 1) {
      cout << 1 << endl;
      continue;
    }
    if (n1 == 2) {
      cout << 2 << endl;
      continue;
    }
    long long int p1 = n1 / 2;
    p1 = p1 + 1;
    cout << p1 << endl;
  }
}
