a = 0 b = 0 c = input().split(';') for item in c: if item[1:].isdigit(): if item[0] == 'A': a -= int(item[1:]) elif item[0] == 'D': a += int(item[...