#include<bits/stdc++.h>
#define forr(i,l,r) for(int i=l;i<=r;i++)
#define ffor(i,r,l) for(int i=r;i>=l;i--)
#define int long long
using namespace std;
const int M=1e6+10;
int to[M<<1],head[M],nt[M<<1],d[M<<1],cnt,ans;
int n,m;
void add(int u,int v,int w)
{
	to[++cnt]=v;
	d[cnt]=w;
	nt[cnt]=head[u];
	head[u]=cnt;
}
int dis[M],vis[M<<1],gl[M];
void dfs(int x)
{
	if(x==2*m+n)
	{
//		cout<<"qwq";
		memset(gl,0,sizeof(gl));
		forr(j,1,n)
		{
			if(dis[j]&&!gl[j])
			{
				gl[j]=1;
				for(int i=head[j];i&&(!gl[to[i]]);i=nt[i])
				{
					if(dis[to[i]]&&!vis[i])
					{
						return;
					}
				}
			}
		}
		ans++;
//		cout<<ans<<endl;
	}
	if(x<n)
	{
		dis[++x]=1;
		dfs(x);
		dis[x]=0;
		dfs(x);
	}
	else
	{
		x+=2;
		vis[(x-1)-n+1]=1;
		vis[(x)-n+1]=1;
		dfs(x);
		vis[(x-1)-n+1]=0;
		vis[(x)-n+1]=0;
		dfs(x);
	}
}
signed main()
{
	freopen("barrack.in","r",stdin);
	freopen("barrack.out","w",stdout);
	cin>>n>>m;
	int u,v;
	forr(i,1,m)
	{
		cin>>u>>v;
		add(u,v,1);
		add(v,u,1);
	}
	dfs(0);
	cout<<ans<<endl;
	return 0;
}