a, b, c = input(), input(), int(input()) print(int(a) + int(b) - int(c)) print(int(a + b) - int(c))