#include <bits/stdc++.h>
using namespace std;
const double PI = acos(-1.0);
struct debugger {
  template <typename T>
  debugger& operator,(const T& v) {
    cerr << v << " ";
    return *this;
  }
} dbg;
int main() {
  int n, k, a, b, c, d, toPrint[1005], i, j;
  scanf("%d %d", &n, &k);
  scanf("%d %d %d %d", &a, &b, &c, &d);
  if (n == 4 || k <= n) {
    printf("-1\n");
    return 0;
  }
  toPrint[0] = a;
  toPrint[1] = c;
  toPrint[n - 2] = d;
  toPrint[n - 1] = b;
  j = 2;
  for (i = 1; i <= n; i++) {
    if (i == a || i == b || i == c || i == d) continue;
    toPrint[j++] = i;
  }
  for (i = 0; i < n - 1; i++) printf("%d ", toPrint[i]);
  printf("%d\n", toPrint[i]);
  swap(toPrint[0], toPrint[1]);
  swap(toPrint[n - 2], toPrint[n - 1]);
  for (i = 0; i < n - 1; i++) printf("%d ", toPrint[i]);
  printf("%d\n", toPrint[i]);
  return 0;
}
