问题3699--A simple task

3699: A simple task

[命题人 : ]
时间限制 : 5.000 sec  内存限制 : 162 MB

题目描述

A Simple Task Given a simple graph, output the number of simple cycles in it. A simple cycle is a cycle with no repeated vertices or edges.

输入

The first line of input contains two integers n and m (1 ≤ n ≤ 19, 0 ≤ m) – respectively the number of vertices and edges of the graph. Each of the subsequent m lines contains two integers a and b, (1 ≤ a, b ≤ n, a ≠ b) indicating that vertices a and b are connected by an undirected edge. There is no more than one edge connecting any pair of vertices.

输出

Output the number of cycles in the given graph.

样例输入 Copy

3 2
1 2
2 3

样例输出 Copy

0

来源/分类