#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, k;
  cin >> n >> k;
  int a, b, c, d;
  cin >> a >> b >> c >> d;
  if (k < (n + 1) or n == 4)
    cout << -1 << endl;
  else {
    vector<int> v;
    for (int i = 1; i <= n; i++)
      if (i != a and i != b and i != c and i != d) v.push_back(i);
    cout << a << ' ' << c << ' ';
    for (int i : v) cout << i << ' ';
    cout << d << ' ' << b << endl;
    cout << c << ' ' << a << ' ';
    for (int i : v) cout << i << ' ';
    cout << b << ' ' << d << endl;
  }
}
