#include <bits/stdc++.h>
using namespace std;
int n, k, a, b, c, d;
vector<int> v;
int main() {
  cin >> n >> k;
  cin >> a >> b >> c >> d;
  if (k <= n || n == 4) {
    cout << -1 << endl;
    return 0;
  }
  for (int i = 1; i <= n; i++) {
    if (i == a || i == b || i == c || i == d) continue;
    v.push_back(i);
  }
  cout << a << ' ';
  for (int i = 0; i < v.size() - 1; i++) printf("%d ", v[i]);
  int len = v.size();
  cout << c << ' ' << v[len - 1] << ' ' << d << ' ' << b << endl;
  cout << c << ' ';
  for (int i = v.size() - 2; i >= 0; i--) printf("%d ", v[i]);
  cout << a << ' ' << v[len - 1] << ' ' << b << ' ' << d << endl;
  return 0;
}
