#include <bits/stdc++.h>
using namespace std;
set<pair<int, int> > V;
int p[102345];
int main() {
  int n, m, x, y;
  scanf("%d%d", &n, &m);
  for (int i = 1; i <= m; i++) {
    scanf("%d%d", &x, &y);
    V.insert(make_pair(x, y));
    V.insert(make_pair(y, x));
  }
  for (int i = 0; i < n; i++) p[i] = i + 1;
  int tim = 16384;
  bool flag = false;
  while (tim && !flag) {
    random_shuffle(p, p + n);
    p[n] = p[0];
    int cnt = 0;
    for (int i = 0; i < n; i++) {
      if (!V.count(pair<int, int>(p[i], p[i + 1]))) cnt++;
      if (cnt == m) {
        for (int i = 0; m > 0; i++) {
          if (!V.count(pair<int, int>(p[i], p[i + 1]))) {
            printf("%d %d\n", p[i], p[i + 1]);
            m--;
          }
        }
        flag = true;
        break;
      }
    }
    tim--;
  }
  if (!flag) puts("-1");
  return 0;
}
