s = input() if s.find("+-") != -1: s = s.replace("+-", "--") elif s.find("--") != -1: s = s.replace("--", "+-") elif s.find("++") != -1: s = s.replace("++", "-+") elif s.find("-+") != -1: s = s.replace("-+", "++") else: l = len(s) - 1 while True: if s[l] == '+': s = s[:l] + '-' + s[l+1:] break if s[l] == '-': s = s[:l] + '+' + s[l+1:] break l -= 1 print(eval(s))