#include <bits/stdc++.h>
using namespace std;
int p[1003], m[1003];
int main() {
  ios_base::sync_with_stdio(0);
  int n, k, a, b, c, d;
  cin >> n >> k >> a >> b >> c >> d;
  if (k <= n || n == 4) {
    cout << "-1";
    return 0;
  }
  cout << a << " " << c << " ";
  m[a] = 1;
  int q = 0;
  for (int i = 1; i < n + 1; i++) {
    if (!m[i] && i != c && i != d && i != b) {
      cout << i << " ";
      p[q++] = i;
    }
  }
  cout << d << " " << b << endl << c << " " << a << " ";
  for (int i = 0; i < q; i++) {
    cout << p[i] << " ";
  }
  cout << b << " " << d << endl;
  return 0;
}
