#include <bits/stdc++.h>
using namespace std;
inline int read() {
  int x = 0, f = 1;
  char ch = getchar();
  while (ch < '0' || ch > '9') {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9') {
    x = x * 10 + ch - '0';
    ch = getchar();
  }
  return x * f;
}
struct mps {
  bitset<30> s[30];
} S;
int n, m, xx, Ans;
inline void dfs(int x, int s, mps SS) {
  if (x == n + 1) {
    int fg = 1;
    for (int i = 1; i <= n; i++)
      if (SS.s[i].count() != n) {
        fg = 0;
        break;
      }
    if (fg) Ans = s;
    return;
  }
  dfs(x + 1, s, SS);
  if (__builtin_popcount(s) + 1 < __builtin_popcount(Ans)) {
    for (int i = 1; i <= n; i++)
      if (SS.s[x][i]) SS.s[i] |= SS.s[x];
    dfs(x + 1, s | (1 << (x - 1)), SS);
  }
}
int main() {
  n = read();
  m = read();
  Ans = (1 << n) - 1;
  for (int i = 1; i <= m; i++) {
    int u = read(), v = read();
    S.s[u][v] = 1;
    S.s[v][u] = 1;
  }
  for (int i = 1; i <= n; i++) S.s[i][i] = 1;
  dfs(1, 0, S);
  printf("%d\n", __builtin_popcount(Ans));
  for (int i = 1; i <= n; i++)
    if (Ans & (1 << (i - 1))) printf("%d ", i);
  puts("");
  return 0;
}
