S = input() + "*" ans = 0 ope = "*" T = "" for s in S: if s.isdigit(): T += s else: if ope == "*": ans += int(T) else: ans *= int(T) T = "" ope = s print(ans)