console.log((args=>{
  const [[N,M],...tmp] = args.trim().split('\n').map(r=>r.split(' ').map(v=>v|0));
  const G = Array.from({length:N},_=>[]);
  for ( let i = 0; i < M; i++ ) {
    const [a,b] = tmp[i];
    G[a-1].push(b-1);
    G[b-1].push(a-1);
  }
  const stack = [[0,1]];
  const ALL = (1<<N)-1;
  let count = 0;
  while ( stack.length ) {
    const [i,a] = stack.pop();
    for ( const j of G[i] ) {
      const c = a|1<<j;
      if ( c === ALL ) count++;
      else if ( c !== a ) stack.push([j,c]);
    }
  }
  return `${count}`;
})(require('fs').readFileSync('/dev/stdin', 'utf8')));
