from decimal import Decimal p,c=map(int,raw_input().split()) print Decimal(str(41**p*49**c))/Decimal(str(6**(p+c)))