#include <bits/stdc++.h>
using namespace std;
const long long mod = 1e9 + 7;
long long dx[] = {-1, 0, 1, 0};
long long dy[] = {0, -1, 0, 1};
vector<long long> g[3005], vis(3005);
set<long long> cycle;
stack<long long> s;
bool dfs(long long x, long long p) {
  vis[x] = 1;
  s.push(x);
  for (auto i : g[x]) {
    if (vis[i] && i != p) {
      while (s.top() != i) {
        cycle.insert(s.top());
        s.pop();
      }
      cycle.insert(i);
      return 0;
    } else if (!vis[i]) {
      if (!dfs(i, x)) return 0;
    }
  }
  s.pop();
  return 1;
}
int32_t main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  long long n, k;
  cin >> n >> k;
  long long a, b, c, d;
  cin >> a >> b >> c >> d;
  if (n == 4) {
    cout << -1 << "\n";
    return 0;
  }
  if (k < n + 1) {
    cout << -1 << "\n";
    return 0;
  }
  vector<long long> v;
  for (long long i = 1; i <= n; i++) {
    if (i == a || i == b || i == c || i == d) continue;
    v.push_back(i);
  }
  cout << a << " " << c << " ";
  for (long long i = 0; i < v.size(); i++) {
    cout << v[i] << " ";
  }
  cout << d << " " << b << "\n";
  cout << c << " " << a << " ";
  for (long long i = 0; i < v.size(); i++) {
    cout << v[i] << " ";
  }
  cout << b << " " << d << "\n";
}
