#include <bits/stdc++.h>
using namespace std;
const int N = 5050;
int main() {
  int n, k, a, b, c, d;
  cin >> n >> k;
  cin >> a >> b >> c >> d;
  if (n >= k || n == 4)
    puts("-1");
  else {
    cout << a << " " << c << " ";
    for (int i = 1; i <= n; i++) {
      if (i != a && i != b && i != c && i != d) {
        cout << i << " ";
      }
    }
    cout << d << " " << b << endl;
    cout << c << " " << a << " ";
    for (int i = 1; i <= n; i++) {
      if (i != a && i != b && i != c && i != d) {
        cout << i << " ";
      }
    }
    cout << b << " " << d << endl;
  }
  return 0;
}
