#include <bits/stdc++.h>
using namespace std;
bool deb = false;
int i;
const int N = 100011;
int g[N];
int ans1[N], ans2[N];
int main() {
  int i, j, n, k;
  scanf("%d", &n), scanf("%d", &k);
  int a, b, c, d;
  scanf("%d", &a), scanf("%d", &b), scanf("%d", &c), scanf("%d", &d);
  if (k < n + 1 || n == 4) {
    printf("%d\n", -1);
    return 0;
  }
  g[1] = a;
  g[2] = c;
  g[n] = b, g[n - 1] = d;
  j = 3;
  for (i = 1; i < n + 1; ++i) {
    if (i == a || i == b || i == c || i == d) continue;
    if (g[j] == 0) g[j] = i, j++;
  }
  for (i = 1; i < n + 1; ++i) printf("%d ", g[i]);
  printf("\n");
  printf("%d ", g[2]), printf("%d ", g[1]);
  for (i = 3; i < n - 1; ++i) {
    printf("%d ", g[i]);
  }
  printf("%d ", g[n]), printf("%d\n", g[n - 1]);
  return 0;
}
