P,C = raw_input().split(' ') sosu = [2,3,5,7,11,13] gouseisu = [4,6,8,9,10,12] s_num = 1.0 g_num = 1.0 for s in sosu: s_num = s_num * s s_num /= 6 for g in gouseisu: g_num = g_num * g g_num /= 6 P = int(P) C = int(C) if P == 0: output = g_num**C elif C == 0: output = s_num**P else: output = (s_num**P) * (g_num**C) print output