#include <bits/stdc++.h>
using namespace std;
bool solved;
const int MX = 1500000;
int cache_map[1 << 22];
int nxt;
int cache[MX][22];
void check_solution(vector<int>& g, vector<int>& sol, int n) {
  int mask(0);
  int ind(nxt);
  nxt += 1;
  if (nxt == MX) nxt = 0;
  if (((int)sol.size()) != 1) {
    for (int i(0), _l((int)(((int)sol.size())) - 1); i <= _l; ++i)
      mask |= (1 << sol[i]);
    int mask_prev = mask ^ (1 << sol.back());
    int ind_prev(cache_map[mask_prev]);
    memcpy(cache[ind], cache[ind_prev], 22 * sizeof(int));
  } else {
    mask |= (1 << sol.back());
    for (int i(0), _l((int)(n)-1); i <= _l; ++i) cache[ind][i] = g[i];
  }
  cache_map[mask] = ind;
  int v(sol.back());
  for (int j(0), _l((int)(n)-1); j <= _l; ++j) {
    if ((cache[ind][v] & (1 << j)) != 0) {
      cache[ind][j] |= cache[ind][v];
    }
  }
  int need((1 << n) - 1);
  for (int i(0), _l((int)(n)-1); i <= _l; ++i)
    if (cache[ind][i] != need) return;
  printf("%d\n", ((int)sol.size()));
  for (int i(0), _l((int)(((int)sol.size())) - 1); i <= _l; ++i)
    printf("%d%c", sol[i] + 1, i + 1 == ((int)sol.size()) ? '\n' : ' ');
  solved = true;
}
void try_solve(vector<int>& g, int n, int k, vector<int>& cur, int ind) {
  if (solved) return;
  if (((int)cur.size()) == k) {
    check_solution(g, cur, n);
  } else {
    if (ind == n) return;
    cur.push_back(ind);
    try_solve(g, n, k, cur, ind + 1);
    cur.pop_back();
    if (solved) return;
    try_solve(g, n, k, cur, ind + 1);
  }
}
void solve() {
  nxt = 0;
  int n, m;
  scanf("%d%d", &n, &m);
  vector<int> g(n);
  for (int i(0), _l((int)(n)-1); i <= _l; ++i) {
    g[i] |= (1 << i);
  }
  for (int i(0), _l((int)(m)-1); i <= _l; ++i) {
    int a, b;
    scanf("%d%d", &a, &b);
    --a, --b;
    g[a] |= (1 << b);
    g[b] |= (1 << a);
  }
  if (m == n * (n - 1) / 2) {
    puts("0");
    return;
  }
  solved = false;
  vector<int> s;
  for (int i(1), _l(n); i <= _l; ++i) {
    try_solve(g, n, i, s, 0);
    if (solved) break;
  }
}
int main() {
  solve();
  return 0;
}
