#include <bits/stdc++.h>
using namespace std;
bool home = 1;
signed realMain();
mt19937 rng_home(0);
mt19937 rng_oj((long long)(new char));
long long rng() {
  if (home) {
    return rng_home();
  } else {
    return rng_oj();
  }
}
unsigned long long rng_ull() {
  return (unsigned long long)rng() * rng() ^
         ((unsigned long long)rng() * rng());
}
long long rng_range(long long l, long long r) {
  return l + abs(rng()) % (r - l + 1);
}
signed main() {
  home = 0;
  if (home) {
    freopen("tony_stark", "r", stdin);
  } else {
    ios::sync_with_stdio(0);
    cin.tie(0);
  }
  realMain();
}
const long long N = 40;
long long n, m, edges[N];
vector<long long> g[N];
long long nr_componente() {
  vector<bool> vis(n, 0);
  long long ret = 0;
  for (long long i = 0; i < n; i++) {
    if (vis[i]) continue;
    ret++;
    queue<long long> q;
    q.push(i);
    vis[i] = 1;
    while (!q.empty()) {
      long long x = q.front();
      q.pop();
      for (auto &y : g[x]) {
        if (!vis[y]) {
          q.push(y);
          vis[y] = 1;
        }
      }
    }
  }
  return ret;
}
bool bip() {
  vector<bool> vis(n, 0);
  vector<long long> col(n, -1);
  for (long long i = 0; i < n; i++) {
    if (vis[i]) continue;
    queue<long long> q;
    q.push(i);
    vis[i] = 1;
    col[i] = 0;
    while (!q.empty()) {
      long long x = q.front();
      q.pop();
      for (auto &y : g[x]) {
        if (!vis[y]) {
          q.push(y);
          vis[y] = 1;
          col[y] = col[x] ^ 1;
        }
      }
    }
  }
  for (long long i = 0; i < n; i++) {
    for (auto &j : g[i]) {
      if (col[i] == col[j]) return 0;
    }
  }
  return 1;
}
long long cnt[1 << (N / 2)];
signed realMain() {
  cin >> n >> m;
  if (m == 0) {
    cout << "0\n";
    return 0;
  }
  for (long long i = 1; i <= m; i++) {
    long long x, y;
    cin >> x >> y;
    x--;
    y--;
    edges[x] |= (1LL << y);
    edges[y] |= (1LL << x);
    g[x].push_back(y);
    g[y].push_back(x);
  }
  long long ret = (1LL << n) - (1LL << nr_componente()), izolate = 0;
  for (long long i = 0; i < n; i++) {
    if (g[i].empty()) izolate++;
  }
  ret += 2 * (1LL << izolate);
  if (bip()) ret += (1LL << nr_componente());
  long long sol = 0;
  long long n1 = n / 2, n2 = n - n / 2;
  for (long long mask = 0; mask < (1LL << n1); mask++) {
    bool indep = 1;
    for (long long i = 0; i < n1; i++) {
      if (mask & (1 << i)) {
        if (edges[i] & mask) indep = 0;
      }
    }
    if (indep) {
      cnt[mask]++;
    }
  }
  for (long long bit = 0; bit < n1; bit++) {
    for (long long i = 0; i < (1 << n1); i++) {
      if (i & (1 << bit)) {
        cnt[i] += cnt[i - (1 << bit)];
      }
    }
  }
  for (long long mask = 0; mask < (1LL << n2); mask++) {
    bool indep = 1;
    long long nope = 0;
    for (long long i = 0; i < n2; i++) {
      if (mask & (1 << i)) {
        nope |= edges[i + n1];
        if (edges[i + n1] & (mask * (1LL << n1))) indep = 0;
      }
    }
    if (indep) {
      nope &= ((1 << n1) - 1);
      nope = (1 << n1) - 1 - nope;
      sol += cnt[nope];
    }
  }
  ret -= 2 * sol;
  cout << ret << "\n";
  return 0;
}
