#include <bits/stdc++.h>
using namespace std;
int dx[] = {-1, 1, 0, 0};
int dy[] = {0, 0, -1, 1};
int n, k, a, b, c, d;
void solve() {
  if (n >= 5) {
    if (k >= n + 1) {
      vector<int> l;
      for (int i = 1; i <= n; i++)
        if (i != a && i != b && i != c && i != d) {
          l.push_back(i);
        }
      printf("%d %d ", a, c);
      for (int i : l) printf("%d ", i);
      printf("%d %d\n", d, b);
      printf("%d %d ", c, a);
      for (int i : l) printf("%d ", i);
      printf("%d %d\n", b, d);
    } else
      printf("-1\n");
  } else
    printf("-1\n");
}
int main() {
  cin >> n >> k >> a >> b >> c >> d;
  solve();
  return 0;
}
