import java.util.Scanner; class paiza { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int length = sc.nextInt(); int num = sc.nextInt(); String codon[] = new String[num]; for (int i = 0; i < num; i++) { codon[i] = sc.next(); } System.out.println( (int)Math.pow(2, (length - codon[0].length())) * num ); } }