#include <bits/stdc++.h>
using namespace std;
const int N = 45;
template <typename T>
inline void read(T &AKNOI) {
  T x = 0, flag = 1;
  char ch = getchar();
  while (!isdigit(ch)) {
    if (ch == '-') flag = -1;
    ch = getchar();
  }
  while (isdigit(ch)) {
    x = x * 10 + ch - '0';
    ch = getchar();
  }
  AKNOI = flag * x;
}
int n, m, g[N][N];
int dp[(1 << 20) + 5], h, len;
long long e[N], wow;
void DFS1(int u, int mx, int s) {
  if (u == mx) {
    dp[s] = 1;
    return;
  }
  DFS1(u + 1, mx, s);
  if (!(e[u] & s)) {
    DFS1(u + 1, mx, s | (1 << u));
  }
}
void DFS2(int u, int mx, long long s) {
  if (u == mx) {
    wow += dp[(s & (len - 1)) ^ (len - 1)];
    return;
  }
  DFS2(u + 1, mx, s);
  if (!((s >> u) & 1)) {
    DFS2(u + 1, mx, s | e[u]);
  }
}
inline long long Calc1() {
  h = (n >> 1), len = (1 << h);
  DFS1(0, h, 0);
  for (int i = 1; i < len; i <<= 1) {
    for (int j = 0; j < len; j += (i << 1)) {
      for (int k = 0; k < i; ++k) {
        dp[j + k + i] += dp[j + k];
      }
    }
  }
  DFS2(h, n, 0);
  return wow;
}
int fa[N], siz[N];
int getf(int x) { return (fa[x] == x) ? x : fa[x] = getf(fa[x]); }
inline long long Calc2() {
  for (int i = 0; i < n; ++i) {
    fa[i] = i;
    siz[i] = 1;
  }
  for (int i = 0; i < n; ++i) {
    for (int j = i + 1; j < n; ++j) {
      if (!g[i][j]) continue;
      int u = getf(i), v = getf(j);
      if (u == v) continue;
      fa[u] = v;
      siz[v] += siz[u];
    }
  }
  int cnt = 0;
  for (int i = 0; i < n; ++i) {
    cnt += (getf(i) == i);
  }
  return (1LL << cnt);
}
inline long long Calc3() {
  int cnt = 0;
  for (int i = 0; i < n; ++i) {
    cnt += (getf(i) == i && siz[i] == 1);
  }
  return (1LL << cnt);
}
int q[N], head, tail, col[N];
inline long long Calc4() {
  memset(col, -1, sizeof(col));
  head = 1, tail = 0;
  int cnt = 0;
  for (int i = 0; i < n; ++i) {
    if (getf(i) == i) {
      ++cnt;
      q[++tail] = i;
      col[i] = 0;
    }
  }
  while (head <= tail) {
    int u = q[head++];
    for (int v = 0; v < n; ++v) {
      if (!g[u][v]) continue;
      if (col[v] == -1) {
        col[v] = col[u] ^ 1;
        q[++tail] = v;
      } else if (col[v] == col[u]) {
        return 0;
      }
    }
  }
  return (1LL << cnt);
}
void init() {
  read(n);
  read(m);
  for (int i = 1, u, v; i <= m; ++i) {
    read(u);
    --u;
    read(v);
    --v;
    g[u][v] = g[v][u] = 1;
    e[u] |= (1LL << v);
    e[v] |= (1LL << u);
  }
}
void solve() {
  if (m < 3) {
    printf("0\n");
    return;
  }
  long long ans = (1LL << n);
  ans -= Calc1() * 2;
  ans -= Calc2();
  ans += Calc3() * 2;
  ans += Calc4();
  printf("%lld\n", ans);
}
int main() {
  init();
  solve();
  return 0;
}
