#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;
  int m;
  if (n == 4)
    m = 4;
  else
    m = n - 1 + 2;
  if (m > k || n == 4) {
    cout << -1 << endl;
    return 0;
  }
  set<int> s;
  for (int i = 1; i <= n; i++) s.insert(i);
  s.erase(a);
  s.erase(b);
  s.erase(c);
  s.erase(d);
  cout << a << " " << c << " ";
  for (int v : s) cout << v << " ";
  cout << d << " " << b << endl;
  cout << c << " " << a << " ";
  for (int v : s) cout << v << " ";
  cout << b << " " << d << endl;
}
