#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    if (n < 4) {
      cout << -1 << endl;
      continue;
    }
    int start;
    if (n % 2 == 0) {
      start = 2;
    } else {
      start = 1;
    }
    for (int i = start; i <= n; i += 2) {
      cout << i << " ";
    }
    cout << n - 3 << " ";
    cout << n - 1 << " ";
    for (int i = n - 5; i >= 1; i -= 2) {
      cout << i << " ";
    }
    cout << endl;
  }
  return 0;
}
