#include <bits/stdc++.h>
using namespace std;
long long a, c, d, e, f, g, h, i, j, k, l, m, n, o, p, s;
int main() {
  cin >> n;
  k = 0;
  long long b[n];
  for (i = 0; i < n; ++i) {
    cin >> m;
    cout << m / 2 << endl;
  }
  return 0;
}
