#include <bits/stdc++.h>
using namespace std;
void ga(int N, int *A) {
  for (int i(0); i < N; i++) scanf("%d", A + i);
}
#pragma GCC optimize("Ofast")
#pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")
int N, M, g[22], a, b, D[(1 << 22)], C[(1 << 22)], B[(1 << 22)];
bool cq(int b) {
  int B = b;
  for (int i(0); i < N; i++)
    if (b & 1 << i) B &= g[i];
  return b == B;
}
int main(void) {
  scanf("%d%d", &N, &M), (memset(D, 63, sizeof(D)));
  for (int i(0); i < N; i++) g[i] |= 1 << i;
  for (int i(0); i < M; i++)
    scanf("%d%d", &a, &b), --a, --b, g[a] |= 1 << b, g[b] |= 1 << a;
  for (int i(0); i < 1 << N; i++)
    if (i) {
      if (cq(i)) D[i] = 0, C[i] = -1;
      for (int j(0); j < N; j++)
        if (i & 1 << j)
          if (D[i | g[j]] > D[i] + 1)
            D[i | g[j]] = D[i] + 1, C[i | g[j]] = i, B[i | g[j]] = j;
    }
  a = (1 << N) - 1, printf("%d\n", D[a]);
  while (~C[a]) printf("%d ", B[a] + 1), a = C[a];
  puts("");
  return 0;
}
