#include <bits/stdc++.h>
#define int long long
#define ll long long
#define ri register
#define in inline
#define INF 0x3f3f3f3f
using namespace std;
const int N=5e5+10;
const int mod=1e9+7;
vector<int>e[N];
queue<int>q;
int n,m;
int u[N],v[N];
int ji=1,ni=1,tai[N],mei[N],op[N];
int ans=0;
in void dfs1(int x){
	for(int i=0;i<e[x].size();i++){
		int y=e[x][i];
		if(!op[y]){
			op[y]=1;
			dfs1(y);
		}
	}
}
in void dfs(int x,int y,int z){
	int o=1,p=1,cnt=0;
	while(x){
		if(x%2==1) tai[o]=1,cnt++;
		x/=2;
		o++;
	}
	while(y){
		if(y%2==1) mei[p]=1;
		y/=2;
		p++;
	}
	if(mei[z]==1) return;
	for(int i=1;i<=n;i++){
		if(tai[i]==1){
			op[i]=1;
			dfs1(i);
		}
	}
	int flag=0;
	for(int i=1;i<=n;i++){
		if(tai[i]==1&&op[i]==1){
			flag++;
		}
	}
	if(flag==cnt) ans++;
	return;
}
signed main(){
	freopen("barrack.in","r",stdin);
	freopen("barrack.out","w",stdout);
	cin >> n >> m;
	for(int i=1;i<=m;i++){
		cin >> u[i] >> v[i];
		e[u[i]].push_back(v[i]);
		e[v[i]].push_back(u[i]);
	}
	for(int i=1;i<=n;i++){
		ji=ji*2;
	}
	for(int i=1;i<=m;i++){
		ni=ni*2;
	}
	for(int i=1;i<ji;i++){
		for(int j=0;j<ni;j++){
			for(int k=1;k<=m;k++){
				memset(tai,0,sizeof(tai));
				memset(mei,0,sizeof(mei));
				memset(op,0,sizeof(op));
				dfs(i,j,k);
			}
		}
	}
	cout << ans;
}