#include <bits/stdc++.h>
using namespace std;
set<pair<int, int>> edges;
vector<int> adia[100010];
vector<int> newadia[100010];
int cnt;
int h[100010];
int up[100010];
int nou[100010];
int nr_frunze;
vector<int> one_old[100010];
int g[100010];
bool viz[100010];
vector<int> fii[100010];
set<int> frunzeact;
void dfs(int nod, int tata) {
  up[nod] = 1 + h[tata];
  h[nod] = 1 + h[tata];
  for (auto i : adia[nod]) {
    if (i == tata) continue;
    if (h[i])
      up[nod] = min(up[nod], h[i]);
    else {
      dfs(i, nod);
      up[nod] = min(up[nod], up[i]);
    }
  }
}
void get_comp(int nod, int col) {
  viz[nod] = 1;
  nou[nod] = col;
  one_old[col].push_back(nod);
  for (auto i : adia[nod]) {
    if (!viz[i]) {
      if (up[i] <= h[nod])
        get_comp(i, col);
      else
        get_comp(i, ++cnt);
    }
  }
}
void get_g(int nod, int tata) {
  g[nod] = (newadia[nod].size() == 1);
  for (auto i : newadia[nod]) {
    if (i != tata) {
      get_g(i, nod);
      g[nod] += g[i];
    }
  }
}
int get_centr(int nod, int tata) {
  for (auto i : newadia[nod]) {
    if (i == tata) continue;
    if (2 * g[i] >= g[1]) return get_centr(i, nod);
  }
  return nod;
}
int get_frunze(int nod, int tata) {
  if (newadia[nod].size() == 1) {
    fii[nod].push_back(nod);
    return nod;
  }
  int ans(nod);
  for (auto i : newadia[nod]) {
    if (i == tata) continue;
    int q = get_frunze(i, nod);
    if (fii[q].size() > fii[ans].size()) swap(ans, q);
    for (auto j : fii[q]) fii[ans].push_back(j);
  }
  return ans;
}
int main() {
  int n, m, a, b;
  cin >> n >> m;
  while (m--) {
    cin >> a >> b;
    adia[a].push_back(b);
    adia[b].push_back(a);
    edges.insert({a, b});
    edges.insert({b, a});
  }
  if (n == 2) {
    cout << "-1\n";
    return 0;
  }
  dfs(1, 0);
  cnt = 1;
  get_comp(1, 1);
  for (int i(1); i <= n; i++)
    for (auto j : adia[i]) newadia[nou[i]].push_back(j);
  for (int i(1); i <= cnt; i++) {
    for (int j(0); j < newadia[i].size(); j++) {
      newadia[i][j] = nou[newadia[i][j]];
      if (newadia[i][j] == i) {
        swap(newadia[i][j], newadia[i][newadia[i].size() - 1]);
        newadia[i].pop_back();
        j--;
      }
    }
    sort(newadia[i].begin(), newadia[i].end());
    newadia[i].resize(unique(newadia[i].begin(), newadia[i].end()) -
                      newadia[i].begin());
  }
  int s1(0);
  for (int i(1); i <= cnt; i++) s1 += newadia[i].size();
  assert(s1 == 2 * (cnt - 1));
  get_g(1, 0);
  int centr = get_centr(1, 0);
  priority_queue<pair<int, int>> q;
  set<int> s;
  for (auto i : newadia[centr]) {
    int z = get_frunze(i, centr);
    q.push({fii[z].size(), z});
    for (auto j : fii[z]) {
      assert(s.find(j) == s.end());
      s.insert(j);
    }
  }
  assert(s.size() + (newadia[centr].size() == 1) == g[1]);
  int ans(0);
  int a1 = 0, p1, a2 = 0, p2;
  vector<pair<int, int>> vans;
  while (!q.empty()) {
    auto i = q.top();
    q.pop();
    if (q.empty()) {
      if (i.second != p1 && a1)
        vans.push_back({fii[i.second].back(), a1});
      else if (i.second != p2 && a2)
        vans.push_back({fii[i.second].back(), a2});
      else
        vans.push_back({fii[i.second].back(), centr});
      fii[i.second].pop_back();
      i.first--;
      if (i.first) q.push(i);
      ans++;
    } else {
      ans++;
      auto j = q.top();
      q.pop();
      a1 = fii[i.second].back(), p1 = i.second;
      a2 = fii[j.second].back(), p2 = j.second;
      vans.push_back({fii[i.second].back(), fii[j.second].back()});
      fii[i.second].pop_back();
      fii[j.second].pop_back();
      i.first--;
      j.first--;
      if (i.first) q.push(i);
      if (j.first) q.push(j);
    }
  }
  for (auto& i : vans)
    if (i.first > i.second) swap(i.first, i.second);
  sort(vans.begin(), vans.end());
  vans.resize(unique(vans.begin(), vans.end()) - vans.begin());
  cout << vans.size() << '\n';
  for (auto i : vans) {
    bool found(0);
    for (auto j : one_old[i.first]) {
      if (found) break;
      for (auto k : one_old[i.second]) {
        if (found) break;
        if (edges.find({j, k}) == edges.end()) {
          found = 1;
          cout << j << ' ' << k << '\n';
        }
      }
    }
    assert(found);
  }
  return 0;
}
