#include <bits/stdc++.h>
using namespace std;
int n, m, ans = (1 << 23) - 1;
bitset<25> a;
struct mat {
  bitset<25> d[25];
} S;
void dfs(int t, int p, mat x) {
  if (t == n + 1) {
    int g = 0;
    for (int i = 1; i <= n; ++i)
      if (x.d[i] != a) g = 1;
    if (!g)
      if (__builtin_popcount(p) < __builtin_popcount(ans)) ans = p;
    return;
  }
  dfs(t + 1, p, x);
  for (int i = 1; i <= n; ++i)
    if (x.d[i][t]) x.d[i] |= x.d[t];
  dfs(t + 1, p | (1 << (t - 1)), x);
}
int main() {
  scanf("%d%d", &n, &m);
  for (int i = 1; i <= n; ++i) a[i] = 1;
  for (int i = 1; i <= n; ++i) S.d[i][i] = 1;
  for (int i = 1; i <= m; ++i) {
    int a, b;
    scanf("%d%d", &a, &b);
    S.d[a][b] = S.d[b][a] = 1;
  }
  dfs(1, 0, S);
  printf("%d\n", __builtin_popcount(ans));
  for (int i = 1; i <= n; ++i)
    if ((1 << (i - 1)) & ans) printf("%d ", i);
}
