#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 5;
int n, m;
vector<vector<int>> adjList(N);
int arr[N];
vector<vector<int>> newAdjList(N);
unsigned long long int seed =
    chrono::high_resolution_clock::now().time_since_epoch().count();
mt19937 generator(seed);
void permuteArr(int nArr) {
  uniform_int_distribution<int> distribution(1, 6);
  for (int i = 0; i < nArr; i++) arr[i] = i;
  for (int i = 0; i < nArr; i++) {
    uniform_int_distribution<int> distribution(i, nArr - 1);
    int ind = distribution(generator);
    int tmp = arr[i];
    arr[i] = arr[ind];
    arr[ind] = tmp;
  }
}
void clearAdjList() {
  for (int i = 0; i < n; i++) adjList[i].clear();
}
void clearNewAdjList() {
  for (int i = 0; i < n; i++) newAdjList[i].clear();
}
bool isAdj(int u, int v) {
  bool retVal = false;
  if (u == v) retVal = true;
  for (int c : adjList[u]) {
    if (v == c) retVal = true;
  }
  return retVal;
}
bool randomizedSolution(int nArr, int m) {
  if (nArr < 3) return false;
  permuteArr(nArr);
  for (int i = 0; i < m; i++)
    if (isAdj(arr[i], arr[(i + 1) % nArr])) return false;
  return true;
}
void printSol(int nArr, int m) {
  for (int i = 0; i < m; i++)
    cout << arr[i] + 1 << ' ' << arr[(i + 1) % nArr] + 1 << endl;
}
int main() {
  cin >> n >> m;
  int a, b;
  clearAdjList();
  for (int i = 0; i < m; i++) {
    cin >> a >> b;
    a--;
    b--;
    adjList[a].push_back(b);
    adjList[b].push_back(a);
  }
  bool sol = false;
  for (int i = 0; i < 200; i++) {
    sol = randomizedSolution(n, m);
    if (sol) break;
  }
  if (sol)
    printSol(n, m);
  else
    cout << -1 << endl;
  return 0;
}
