p, c = map(int,input().split()) s = [2,3,5,7,11,13] g = [4,6,8,9,10,12] print((sum(s)/6)**p*(sum(g)/6)**c)