import java.util.*; public class preNum{ public static void main(String... args){ Scanner s = new Scanner(System.in); double P = s.nextDouble(); double C = s.nextDouble(); double pre=(double)(2+3+5+7+11+13)/(double)6,mix=(double)(4+6+8+9+10+12)/(double)6; System.out.println(Math.pow(pre,P)*Math.pow(mix,C)); } }