#include <bits/stdc++.h>
using namespace std;
const int INF = (int)1e9;
const long long INF64 = (long long)1e18;
#pragma comment(linker, "/STACK:16777216")
#pragma warning(disable : 4786)
int Set(int N, int pos) { return N = N | (1 << pos); }
int Reset(int N, int pos) { return N = N & ~(1 << pos); }
bool check(int N, int pos) { return (bool)(N & (1 << pos)); }
const int mx = 1 << 29;
int ans, sum, t, n, k, m, tk[1003], a, b, c, d;
int dx[] = {0, 1, -1, 0, 0};
int dy[] = {0, 0, 0, 1, -1};
int main() {
  cin >> n >> k;
  cin >> a >> b >> c >> d;
  tk[a] = 1;
  tk[b] = 1;
  tk[c] = 1;
  tk[d] = 1;
  if (k <= n)
    cout << -1 << "\n";
  else if (n == 4)
    cout << -1 << "\n";
  else {
    printf("%d %d ", a, c);
    for (int i = 1; i <= n; i++) {
      if (!tk[i]) printf("%d ", i);
    }
    printf("%d %d\n", d, b);
    printf("%d %d ", c, a);
    for (int i = 1; i <= n; i++) {
      if (!tk[i]) printf("%d ", i);
    }
    printf("%d %d\n", b, d);
  }
  return 0;
}
