Game theory is an interesting subject in computer science.
SG function is an important concept in game theory. Given a directed acyclic graph G_1 with vertex set V_1 and directed edge set E_1, for each vertex u∈V_1, its SG function sg(u) is defined as: sg(u)=mex(sg(v)∣(u,v)∈E_1) where given a set S of non-negative integers, mex(S) is defined as the smallest non-negative integer which is not in S.
Today, Rikka wants to generalize SG function to undirected graphs. Given an undirected graph G with vertex set V and undirected edge set E, a function f over V is a valid SG function on G if and only if:
Under this definition, there may be many valid SG functions for a graph. Therefore, Rikka wants to further figure out whether there is a connection between these valid SG functions. As the first step, your task is to calculate the number of valid SG functions for a given undirected graph G.
The first line contains two integers n,m (1≤n≤17,0≤m≤2n(n−1)), representing the number of vertices and edges in the graph.
Then m lines follow. Each line contains two integers u_i,v_i (1≤u_i,v_i≤n), representing an edge in the graph.
The input guarantees that there are no self-loops and duplicate edges in the graph.
Output a single line with a single integer, representing the number of valid SG functions.
For simplicity, we use list \[f(1),…,f(n)] to represent a function f.
For the sample input, there are 6 valid SG functions: