#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  cin >> t;
  while (t--) {
    long long int i, j, k, l, r, m, n, x = 0, y = 0, z = 0;
    string s;
    cin >> n;
    vector<int> a, b;
    if (n < 4) {
      cout << "-1\n";
    } else {
      i = 1;
      while (i <= n) {
        a.push_back(i);
        i += 2;
      }
      i = 6;
      b.push_back(4);
      b.push_back(2);
      while (i <= n) {
        b.push_back(i);
        i += 2;
      }
      reverse(b.begin(), b.end());
      for (i = 0; i < b.size(); i++) {
        cout << b[i] << " ";
      }
      for (i = 0; i < a.size(); i++) {
        cout << a[i] << " ";
      }
      cout << "\n";
    }
  }
}
