#include <bits/stdc++.h>
using namespace std;
const int M = 203;
const int N = 14;
struct Edge {
  int v;
  Edge *nxt;
} edge[2 * M];
Edge *NIL, *ecnt;
Edge *head[N];
int n, m, lim;
int a[1 << N], b[1 << N], c[1 << N];
int dp[1 << N], cnt[1 << N];
bool p[N + 1][N + 1][1 << N];
vector<pair<int, int> > ans;
bool vis[N];
int s, now;
inline void AddEdge(int u, int v) {
  ecnt++;
  ecnt->v = v;
  ecnt->nxt = head[u];
  head[u] = ecnt;
}
void Dfs(int u, int fa) {
  vis[u] = true;
  now ^= (1 << u);
  for (Edge *e = head[u]; e != NIL; e = e->nxt) {
    if (e->v == fa || p[s][e->v][now]) continue;
    p[s][e->v][now] = true;
    if (!vis[e->v]) Dfs(e->v, u);
  }
  now ^= (1 << u);
  vis[u] = false;
}
void GetAns(int u, int v, int st) {
  if (!st) {
    ans.push_back(make_pair(u, v));
    return;
  }
  for (Edge *e = head[u]; e != NIL; e = e->nxt) {
    int w = (1 << e->v) & st;
    if (!w) continue;
    w = st ^ w;
    if (p[e->v][v][w]) {
      ans.push_back(make_pair(u, e->v));
      GetAns(e->v, v, w);
      return;
    }
  }
}
int main() {
  NIL = ecnt = &edge[0];
  for (int i = 0; i < (1 << N); i++) cnt[i] = cnt[i >> 1] + (i & 1);
  scanf("%d %d", &n, &m), lim = (1 << n);
  for (int i = 0; i < n; i++) head[i] = NIL;
  for (int i = 1, u, v; i <= m; i++) {
    scanf("%d %d", &u, &v), u--, v--;
    AddEdge(u, v), AddEdge(v, u);
  }
  memset(dp, 0x3f, sizeof(dp));
  for (s = 0; s < n; s++) {
    dp[1 << s] = 0;
    for (Edge *e = head[s]; e != NIL; e = e->nxt) {
      p[s][e->v][0] = true;
      Dfs(e->v, s);
    }
  }
  for (s = 1; s < lim; s++) {
    for (int i = 0; i < n; i++) {
      if (!(s & (1 << i))) continue;
      for (int j = 0; j < n; j++) {
        if (!(s & (1 << j))) continue;
        int t3 = ((1 << n) - 1) ^ s;
        for (int t = t3; t; t = t3 & (t - 1)) {
          if (!p[i][j][t]) continue;
          if (dp[s] + cnt[t] + 1 < dp[s | t]) {
            dp[s | t] = dp[s] + cnt[t] + 1;
            a[s | t] = i, b[s | t] = j, c[s | t] = t;
          }
        }
      }
    }
  }
  for (int i = lim - 1; cnt[i] > 1; i ^= c[i]) GetAns(a[i], b[i], c[i]);
  printf("%d\n", (int)ans.size());
  for (int i = 0; i < (int)ans.size(); i++)
    printf("%d %d\n", ans[i].first + 1, ans[i].second + 1);
  return 0;
}
