s = 0
def Rec(n, m):
    global s
    s += n * m
    if n * m == 1:
        return 
    if(n > m):
        Rec(n // 2, m)
        Rec(n - n // 2, m)
    else: 
        Rec(n, m // 2)
        Rec(n, m - m // 2)
ints = lambda: list(map(int, input().split()))
n, m = ints()
Rec(n * m, 1)
print(s)