#include <bits/stdc++.h>
using namespace std;
long long int power(long long int x, long long int y) {
  if (y == 0)
    return 1;
  else if (y % 2 == 0)
    return power((x * x) % (long long int)1000000007, y / 2);
  else
    return (x * power((x * x) % (long long int)1000000007, (y - 1) / 2)) %
           (long long int)1000000007;
}
long long int modInverse(long long int n) {
  return power(n, (long long int)1000000007 - 2);
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int t = 1;
  cin >> t;
  while (t--) {
    long long int n;
    cin >> n;
    if (n <= 3) {
      cout << -1 << endl;
      continue;
    }
    vector<long long int> a, b;
    a.push_back(1);
    a.push_back(3);
    b.push_back(4);
    b.push_back(2);
    for (long long int i = 5; i <= n; i++) {
      if (i % 2 == 1)
        a.push_back(i);
      else
        b.push_back(i);
    }
    reverse(b.begin(), b.end());
    for (auto j : b) cout << j << " ";
    for (auto j : a) cout << j << " ";
    cout << endl;
  }
  return 0;
}
