#include <iostream>
#include <algorithm>
#include <math.h>
#include <stdio.h>
#include <string.h>
#define N 19
const long long mod=1e9+7;
using namespace std;
int n,m;
int a[N];
long long factorial[(1<<N)],inverse[(1<<N)],dp[N][(1<<N)];

int cmp(int x,int y) { return x>y; }
long long ksm(long long x,long long y)
{
	long long res=1;
	while(y)
	{
		if(y&1) res=res*x%mod;
		x=x*x%mod;
		y>>=1;
	}
	return res;
}
long long assemble(int x,int y) { return factorial[x]*inverse[y]%mod*inverse[x-y]%mod; }
int getbit(int now)
{
	int res=0;
	while(now) { res+=(now&1); now>>=1; }
	return res;
}

int main()
{
	scanf("%d%d",&n,&m);
	for(int i=1;i<=m;i++) scanf("%d",&a[i]);
	sort(a+1,a+m+1,cmp);
	int maxn=(1<<n);
	factorial[0]=1;
	for(int i=1;i<=maxn;i++) factorial[i]=factorial[i-1]*i%mod;//cout<<factorial[maxn]<<endl;
		//求阶乘
	inverse[maxn]=ksm(factorial[maxn],mod-2);
	// cout<<inverse[maxn]<<endl;
	for(int i=maxn-1;i>=0;i--) inverse[i]=inverse[i+1]*(i+1)%mod;
		// for(int i=1;i<=3;i++) cout<<inverse[i]<<endl;
		//求逆元
	dp[0][0]=1;
	for(int i=1;i<=m;i++)
		for(int j=0;j<(1<<n);j++)
		{
			if(dp[i-1][j]) 
			{
				(dp[i][j]=dp[i-1][j]+dp[i][j])%=mod;
				for(int k=0;k<n;k++)
					if(((1<<k)&j)==0)
					{
						dp[i][j|(1<<k)]+=dp[i-1][j]*factorial[(1<<k)]%mod*assemble(maxn-a[i]-j,(1<<k)-1)%mod;
						dp[i][j|(1<<k)]%=mod;
						// cout<<dp[i][j|(1<<k)]<<endl;
					}
			}
		}
	
	long long ans=0;
	for(int i=0;i<(1<<n);i++)
	{
		// cout<<"***"<<endl;
		// cout<<ans<<endl;
		// cout<<(getbit(i)&1)<<" "<<ans<<endl;
		if((getbit(i)&1)!=0) 
		{
			ans=ans-dp[m][i]*factorial[maxn-i-1]%mod+mod;
			// cout<<dp[m][i]<<" "<<factorial[maxn-i-1]<<endl;
			if(ans>=mod) ans-=mod;
		}
		else ans=ans+dp[m][i]*factorial[maxn-i-1]%mod+mod;
		ans=(ans%mod+mod)%mod;
	}
	ans=ans*(1<<n)%mod;
	
	printf("%lld\n",ans);
	return 0;
}