#include <bits/stdc++.h>
using namespace std;
const int N = 22;
int fri[N];
int n, m;
int dp[1 << N];
pair<int, int> pre[1 << N];
void get_ans(vector<int> &vec, int mask) {
  if ((mask & (mask - 1)) == 0) return;
  get_ans(vec, pre[mask].first);
  vec.push_back(pre[mask].second + 1);
}
int main() {
  scanf("%d%d", &n, &m);
  for (int i = 0; i < m; i++) {
    int a, b;
    scanf("%d%d", &a, &b);
    a--, b--;
    fri[a] |= 1 << b;
    fri[b] |= 1 << a;
  }
  if (n * (n - 1) == 2 * m) {
    puts("0\n");
    return 0;
  }
  for (int i = 0; i < (1 << n); i++) dp[i] = -1;
  for (int i = 0; i < n; i++) {
    dp[1 << i] = 0;
  }
  for (int i = 0; i < (1 << n); i++) {
    if (dp[i] == -1) continue;
    for (int j = 0; j < n; j++) {
      if (i >> j & 1) {
        int nmask = i | fri[j];
        if (i != nmask && (dp[nmask] == -1 || dp[i] < dp[nmask])) {
          dp[nmask] = dp[i] + 1;
          pre[nmask] = make_pair(i, j);
        }
      }
    }
  }
  cout << dp[(1 << n) - 1] << endl;
  vector<int> vec;
  get_ans(vec, (1 << n) - 1);
  for (int i = 0; i < vec.size(); i++) {
    cout << vec[i] << " ";
  }
  cout << endl;
  return 0;
}
