#include <bits/stdc++.h>
using namespace std;
inline int read() {
  int f = 1, x = 0;
  char ch = getchar();
  while (!isdigit(ch)) {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  while (isdigit(ch)) {
    x = x * 10 + ch - '0';
    ch = getchar();
  }
  return x * f;
}
inline long long readll() {
  long long f = 1, x = 0;
  char ch = getchar();
  while (!isdigit(ch)) {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  while (isdigit(ch)) {
    x = x * 10 + ch - '0';
    ch = getchar();
  }
  return x * f;
}
int n, m, fa[41], sz[41];
int get_fa(int x) { return (x == fa[x]) ? x : (fa[x] = get_fa(fa[x])); }
void union_s(int x, int y) {
  x = get_fa(x), y = get_fa(y);
  if (x == y) return;
  if (sz[x] > sz[y]) swap(x, y);
  sz[y] += sz[x];
  fa[x] = y;
}
long long g[41], f012, f12, f01, f02, f0, f1, f2, fe, dp[1 << 20];
long long calc_ans() { return f012 - f12 - f01 - f02 + f0 + f1 + f2 - fe; }
int vis[41];
bool dfs(int u) {
  for (int v = 1; v <= n; ++v) {
    if (!(g[u] & (1LL << (v - 1)))) continue;
    if (!vis[v]) {
      vis[v] = 3 - vis[u];
      if (!dfs(v)) return false;
    } else if (vis[v] == vis[u])
      return false;
  }
  return true;
}
bool is_erfentu() {
  bool ans = 1;
  for (int i = 1; i <= n; ++i)
    if (!vis[i]) vis[i] = 1, ans &= dfs(i);
  return ans;
}
int main() {
  n = read();
  m = read();
  for (int i = 1; i <= n; ++i) fa[i] = i, sz[i] = 1;
  for (int i = 1, x, y; i <= m; ++i) {
    x = read(), y = read();
    g[x] |= (1LL << (y - 1));
    g[y] |= (1LL << (x - 1));
    union_s(x, y);
  }
  f012 = (1LL << n);
  int c = 0, c1 = 0;
  for (int i = 1; i <= n; ++i) {
    if (get_fa(i) == i) {
      c++;
      if (sz[i] == 1) c1++;
    }
  }
  f02 = (1LL << c);
  f0 = f2 = (1LL << c1);
  if (is_erfentu())
    f1 = f02;
  else
    f1 = 0;
  if (!m)
    fe = (1LL << n);
  else
    fe = 0;
  int s1 = n / 2, s2 = n - s1;
  for (int i = 0; i < (1 << s1); ++i) {
    bool ok = 1;
    for (int j = 1; j <= s1; ++j) {
      if (!(i & (1 << (j - 1)))) continue;
      for (int k = j + 1; k <= s1; ++k) {
        if (!(i & (1 << (k - 1)))) continue;
        if (g[j] & (1LL << (k - 1))) {
          ok = 0;
          break;
        }
      }
      if (!ok) break;
    }
    dp[i] = ok;
  }
  for (int i = 0; i < s1; ++i) {
    for (int j = 0; j < (1 << s1); ++j) {
      if (!(j & (1 << i))) dp[j ^ (1 << i)] += dp[j];
    }
  }
  for (long long i = 0; i < (1 << s2); ++i) {
    long long ii = (i << s1);
    bool ok = 1;
    for (int j = s1 + 1; j <= n; ++j) {
      if (!(ii & (1LL << (j - 1)))) continue;
      for (int k = j + 1; k <= n; ++k) {
        if (!(ii & (1LL << (k - 1)))) continue;
        if (g[j] & (1LL << (k - 1))) {
          ok = 0;
          break;
        }
      }
      if (!ok) break;
    }
    if (!ok) continue;
    int ss = 0;
    for (int j = 1; j <= s1; ++j) {
      bool ok = 1;
      for (int k = s1 + 1; k <= n; ++k) {
        if (!(ii & (1LL << (k - 1)))) continue;
        if (g[k] & (1LL << (j - 1))) {
          ok = 0;
          break;
        }
      }
      if (ok) ss |= (1 << (j - 1));
    }
    f01 += dp[ss];
  }
  f12 = f01;
  cout << calc_ans() << endl;
  return 0;
}
