Problem:
 Score : 200 points    Problem Statement Takahashi has A cookies, and Aoki has B cookies.
Takahashi will do the following action K times:   If Takahashi has one or more cookies, eat one of his cookies.  Otherwise, if Aoki has one or more cookies, eat one of Aoki's cookies.  If they both have no cookies, do nothing.   In the end, how many cookies will Takahashi and Aoki have, respectively?      Constraints  0 \leq A \leq 10^{12}  0 \leq B \leq 10^{12}  0 \leq K \leq 10^{12}  All values in input are integers.         Input Input is given from Standard Input in the following format:  A  B  K       Output Print the numbers of Takahashi's and Aoki's cookies after K actions.        Sample Input 1 2 3 3      Sample Output 1 0 2  Takahashi will do the following:   He has two cookies, so he eats one of them.  Now he has one cookie left, and he eats it.  Now he has no cookies left, but Aoki has three, so Takahashi eats one of them.   Thus, in the end, Takahashi will have 0 cookies, and Aoki will have 2 .       Sample Input 2 500000000000 500000000000 1000000000000      Sample Output 2 0 0  Watch out for overflows.

Solution (Python):
A,B,K=map(int,input().split())
if A<=K:
    print(0,max(B-(K-A),0))
else:
    print(A-K,B)

Solution (Python):
A, B, K = list(map(int, input().split()))

if A > K:
    print(A - K, B)
else:
    print(0, max(0, B - (K - A)))

Solution (Python):
a,b,k = map(int, input().split())

Takahashi = 0
Aoki = 0

Takahashi = a - k

if Takahashi <= 0:
    Aoki = b + Takahashi
    Takahashi = 0
    if Aoki <= 0:
        Aoki = 0
else:
    Aoki = b

print(Takahashi , Aoki)

Solution (Python):
a,b,k = map(int, input().split())

def ans(a,b,k):
    if a >= k:
        a -= k
        print(a,b)
        return
    else:
        k -= a
        a = 0
        if b >= k:
            b -= k
            print(a,b)
            return
        else:
            print(0,0)
            return

ans(a,b,k)

Solution (Python):
import sys
input = sys.stdin.readline

def main():
    a, b, k = map(int, input().split())
    t = max(0, a - k)
    a = max(0, b - k + a - t)
    print(t, a)


if __name__ == "__main__":
    main()

Solution (Python):
a, b, k = map(int, input().split())
if a > 0:
  if a-k >= 0: 
    print(a-k, b)
  else: 
    if b <= -(a-k):
      print(0,0)
    else:
      print(0, b+(a-k))
else:
  if b > 0:
    if b-k <= 0: 
      print(a,0)
    else:
      print(a,b-k)
  else:
    print(a,b)

Solution (Python):
a, b, c = map(int,input().split())
if a > c:
  print(a-c, b)
elif a + b < c:
  print(0,0)
else:
  print(0,a+b-c)

Solution (Python):
a,b,k = map(int,input().split())

if k<=a:
    a -= k
elif k<a+b:
    b -= k-a
    a = 0
elif k>=a+b:
    a = 0
    b = 0

print(str(a)+" "+str(b))

Solution (Python):
a,b,k=map(int,input().split())
if a>=k:
  a-=k
else:
  k-=a
  a=0
  b-=k
  b=max(0,b)
print(a,b)

Solution (Python):
A,B,K=map(int,input().split())
if K-A>=0:
    K=K-A
    A=0
    if K-B>=0:
       B=0 
    else:
        B=B-K
else:
    A=A-K
print(A,B)

Solution (Python):
A,B,K=map(int,input().split())
if A>=K:
    print(A-K,B)
elif A<K and (A+B)>=K:
    print(0,B+A-K)
else:
    print("0","0")

Solution (Python):
def main():
    A,B,K = list(map(int,input().split()))

    c = K - A
    if(c >= 0):
        result = B-c
        if(result > 0):
            print(0,result)
        else:
            print(0,0)
    else:
        print(A-K,B)


if __name__ == "__main__":
    main()

Solution (Python):
a,b,k = map(int, input().split())

if a <= k:
    k -= a
    a = 0
    if b <= k:
        b = 0
    else:
        b -= k
else:
    a -= k

print(a,b)

Solution (Python):
A, B, K = map(int, input().split())
if A > K:
    print(A-K, B)
if A == K:
    print(0, B)
if (A < K) and (A + B > K) :
    print(0, B - (K - A))
if (A < K) and (A + B <= K) :
    print(0, 0)

Solution (Python):
A, B, K = map(int, input().split())
if A > K:
    print(A-K, B)
if A == K:
    print(0, B)
if A < K:
    print(0, max(0,B - (K - A)))

Solution (Python):
A, B, K = map(int, input().split())
if A>=K:
  print(A-K,B)
elif A+B>=K:
  print(0,A+B-K)
else:
  print(0,0)

Solution (Python):
a,b,k = map(int,input().split())
if a >= k:
    if a-k < 0:
        print(0,b)
    else:
        print(a-k,b)
else:
    if b-(k-a)>0:
        print(0,b-(k-a))
    else:
        print(0,0)

Solution (Python):
A,B,K=map(int,input().split())
if A>=K:
  print (A-K,B)
else:
  if A+B>=K:
    print(0,A+B-K)
  else:
    print(0,0)

Solution (Python):
a,b,k=map(int,input().split())
if k>a:
    k-=a
    a=0
else:
    a-=k
    k=0
if k>b:
    b=0
    k-=b
else:
    b-=k
    k=0
print(a,b)

Solution (Python):
import sys
import math
ta,ao,N= map(int,input().split())

N=N-ta
if N>0:
  ta=0
  N=N-ao
  if N>0:
    print("0 0")
    sys.exit()
  else:
    ao=abs(N)
else:
  ta=abs(N)

    
print(str(ta)+" "+str(ao))

Solution (Python):
a, b, k = map(int,input().split())
if a + b <= k:
    print(0,0)
elif k >= a:
    print(0,b+(a-k))
elif a > k:
    print(a-k,b)

Solution (Python):

"""
Created on Wed Mar  4 00:20:28 2020

@author: Kanaru Sato
"""

A,B,K = list(map(int, input().split()))

if K-(A+B) >= 0:
    print(0,0)
else:
    if A<=K:
        print(0,B-K+A)
    if A>K:
        print(A-K,B)

Solution (Python):
A, B, K = [int(x) for x in input().split(" ")]

if A >= K:
  print("{} {}".format(A-K, B))
elif A < K and A+B >= K:
  print("{} {}".format(0, int(A-K/2+B-K/2)))
else:
  print(0, 0)

Solution (Python):
A,B,K = map(int,input().split())
if A >= K:
  print(A-K,B)
elif B + A - K >= 0:
  print(0,B+A-K)
else:
  print(0,0)

Solution (Python):
a, b, k = map(int, input().split())

if k <= a:
    a -= k
elif a < k < a + b:
    k -= a
    a = 0
    b -= k
else:
    a = 0
    b = 0

print(a, b)

Solution (Python):
a,b,k=map(int,input().split())
print(max(0,a-k),max(0,min(b,a+b-k)))

Solution (Python):
a,b,k=map(int,input().split())

if a>=k:
    a-=k
elif b>=k-a:
    b-=k-a
    a=0
else:
    a=b=0
print(a,b)

Solution (Python):
a, b, k = map(int, input().split())
if a + b <= k:
    print("0 0")
elif a >= k:
    print("{} {}".format(a-k, b))
elif k > a:
    print("{} {}".format(0, b+a-k))

Solution (Python):
A, B, K = [int(_) for _ in input().split()]
if K >= A:
    K -= A
    A = 0
    B -= K
    if B < 0:
        B = 0
else:
    A -= K
print(A, B)

Solution (Python):
A,B,K = map(int,input().split())
if K <= A:
    print(A-K,B)
elif A < K and K <= B + A:
    print(0,A+B-K)
else:
    print(0,0)

Solution (Python):
a,b,k = map(int, input().split())

if a >= k:
  a -= k
elif a < k:
  k -= a
  a = 0
  if b > k:
    b -= k
  elif b <= k:
    b = 0
print(a,b)

Solution (Python):
a, b, k = map(int, input().split())

if a+b <= k: print(0,0)
elif a >= k: print(a-k, b)
else: print(0, b-(k-a))

Solution (Python):
takahashi,aoki,K = list(map(int,input().split()))

if K <= takahashi:
	takahashi -= K
elif K <= takahashi + aoki:
	aoki -= (K-takahashi)
	takahashi = 0
else:
	takahashi = 0
	aoki = 0
print(takahashi,aoki)

Solution (Python):
a, b, k = map(int, input().split())
print(max(a - k, 0), max(b - max(k - a, 0), 0))

Solution (Python):
number = input().split(" ")
A = int(number[0])
B = int(number[1])
K = int(number[2])
if A >= K:
	print(str(A-K) + " " + str(B))
elif B >= K-A:
	print("0" + " " + str(A+B-K))
else:
	print("0" + " " + "0")

Solution (Python):
a, b, k = map(int, input().split())
print(max(a - k, 0), max(b - max(k - a, 0), 0))

Solution (Python):
a,b,k = map(int,input().split())
if k > a+b:
  print(0,0)
elif k > a:
    print(0,a+b-k)
else:
    print(a-k,b)

Solution (Python):
a,b,k = map(int,input().split())
if k > (a+b):
  print(0,0)
elif k > a:
    print(0,a+b-k)
else:
    print(a-k,b)

Solution (Python):
A,B,K=map(int,input().split())
if A+B>=K:
    if A>=K:
        A=A-K
    else:
        B=B-(K-A)
        A=0
else:
    A=0
    B=0

print(A,B)

Solution (Python):








a,b,k = map(int,input().split())

takahasi = a
aoki = b

if k >= takahasi:
    k = k - takahasi
    takahasi = 0
else:
    takahasi -= k
    k = 0

if k >= aoki:
    aoki = 0
else:
    aoki -= k

print(takahasi,aoki)

Solution (Python):
A, B, K = map(int, input().split())

ansA = max(A-K, 0)
K = max(K-A, 0)
ansB = max(B-K, 0)

print(ansA, ansB)

Solution (Python):
a, b, k = list(map(int,input().split()))

if a+b < k:
  a = 0
  b = 0
elif a >= k:
  a -= k
else:
  b = b - (k-a)
  a = 0
print(a,b)

Solution (Python):
a, b, k = list(map(int, input().split()))

if k >= a:
    print(0, max(0, b-k+a))
else:
    print(a-k, b)

Solution (Python):
a, b, k = map(int, input().split())

ta = max(a - k, 0)
ao = b
if ta == 0:
    ao = max(b - (k - a), 0)

print(ta, ao)

Solution (Python):
a, b, k = map(int, input().split(' '))

if a > 0 and k >= a:
	k -= a
	a = 0
elif a > 0:
	a -= k
	k = 0

if b > 0 and k >= b:
	k -= b
	b = 0
elif b > 0:
	b -= k
	k = 0

print(a, b)

Solution (Python):
a,b,k=map(int,input().split())

if a>=0 and b>=0:
    leftover = a - k
    if(leftover>=0):
        print(leftover, b)
    elif(b+leftover >= 0):
        print(0, b+leftover)
    else:
        print(0, 0)

Solution (Python):
a,b,k = map(int, input().split())

print(max(a-k,0), max(b-max(k-a,0),0))

Solution (Python):
a,b,k=map(int,input().split())
if a>=k:
  print(a-k,b)
elif a+b>=k:
  print(0,a+b-k)
else:
  print(0,0)

Solution (Python):
A,B,K=map(int,input().split())

if A>=K:
    print(A-K,B)
elif A+B>=K:
    print(0,A+B-K)
else:
    print(0,0)

Solution (Python):
a,b,k=map(int,input().split())
if a>k:
    a-=k
elif a+b>k:
    b=b-k+a
    a=0
else:
    a=0
    b=0
print(a,b)

Solution (Python):
a, b, k = map(int, input().split())
print(max(0, a - k), max(min(b, a + b - k), 0))

Solution (Python):

import sys


def solve(A: int, B: int, K: int):
    fa = max(0, A - K)
    
    diff = K - (A - fa)
    
    fb = max(0, B - diff)
    
    print(fa, fb)



def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    A = int(next(tokens))  
    B = int(next(tokens))  
    K = int(next(tokens))  
    solve(A, B, K)

if __name__ == '__main__':
    main()

Solution (Python):
a,b,k=map(int,input().split())
print(max(a-k,0),max(b-max(k-a,0),0))

Solution (Python):
a, b, k = map(int, input().split())
c = a+b-k
if c > b:
    print(c-b, b)
else:
    print(0, max(0,c))

Solution (Python):
a, b, k = map(int, input().split())

if a >= k:
    a -= k
    k = 0
else:
    k -= a
    a = 0

if b > k:
    b -= k
else:
    b = 0
        

print(a, b)

Solution (Python):
a, b, k = map(int, input().split())
a = a - k
if a < 0:
    b = b + a
    a = 0
    b = max(0, b)
print(a, b)

Solution (Python):
a,b,k = map(int, input().split())

a -= k
if a < 0:
    b += a

print(str(max(0,a)) + ' ' + str(max(0,b)))

Solution (Python):
a, b, k  = map(int, input().split())
if a + b <=k:
    ansa=0
    ansb=0
elif k>=a:
    ansa=0
    ansb=a+b-k
else:
    ansa=a-k
    ansb=b

print(ansa, ansb)

Solution (Python):
A, B, K = (int(x) for x in input().split(' '))

if A-K < 0:
  
  B = B-(K-A) if (B-(K-A)) >= 0 else 0
  
  A = 0
else:
  A -= K  

print(A,B)

Solution (Python):
A, B, K = map(int, input().split())

if A > K:
    A -= K
else:
    K -= A
    A = 0
    B -= K

if B < 0:
    B = 0

print(A,B)

Solution (Python):
a,b,k = map(int,input().split())

if a >= k :
    al = a - k
    bl = b
else:
    al = 0
    bl = max(a + b - k,0)
    
print(al,bl)

Solution (Python):
inp=input().split()
a = int(inp[0])
b = int(inp[1])
k = int(inp[2])
if (k>=a+b):
    print('0 0')
else:
    if (a>=k):
        print('{} {}'.format(a-k, b))
    else:
        print('0 {}'.format(a+b-k))

Solution (Python):
a,b,k=map(int,input().split())
if a>=k:
    print(a-k, b)
else:
    print(0, max(0,b-(k-a)))

Solution (Python):
A, B, K = map(int, input().split())

e = min([K, A])
a = A - e
e = min([K-e, B])
b = B - e
print(a, b)

Solution (Python):
import sys
input = sys.stdin.readline
MOD = 10**9 + 7
INF = float('INF')

def main():
    a, b, k = list(map(int,input().split()))

    a = a - k
    if a < 0:
        b = b + a
        a = 0
        b = max(0, b)
    print(a, b)

if __name__ == '__main__':
    main()

Solution (Python):
[A,B,K] = list(map(int,input().split()))

if A<=K:
    K = K-A
    A = 0
    if B>=K:
        B=B-K
    else:
        B=0
    
else:
    A=A-K

print(A,B)

Solution (Python):
[A,B,K] = list(map(int,input().split()))

X = max(0,A-K)
Y = max(0,min(B,B-(K-A)))

print(X,Y)

Solution (Python):
import sys
input = lambda: sys.stdin.readline().rstrip()
input_nums = lambda: list(map(int, input().split()))

A, B, K = input_nums()

res_a = A - K if A >= K else 0
remain = K - A
if remain > 0:
    res_b = B - remain if B >= remain else 0
else:
    res_b = B
print('{} {}'.format(res_a, res_b))

Solution (Python):
a, b, k = map(int, input().split())
if k > a:
    k -= a
    a = 0
    if k > b:
        b = 0
    else:
        b -= k
else:
    a -= k
print('{} {}'.format(a, b))

Solution (Python):
from itertools import accumulate, permutations, combinations, product, combinations_with_replacement
from math import floor, ceil, sqrt, factorial, log
from bisect import bisect_left, bisect_right
from collections import Counter, defaultdict
from heapq import heappop, heappush, heappushpop
from itertools import product
import sys
stdin = sys.stdin
mod = 10**9 + 7


def ns(): return stdin.readline().rstrip()


def ni(): return int(ns())


def na(): return list(map(int, stdin.readline().split()))


a, b, k = na()
if a > k:

    print(a - k, b)
elif (a + b) > k:
    print(0, a + b - k)
else:
    print(0, 0)

Solution (Python):
a, b, k = map(int, input().split())
f = max(0, a - k)
k = max(0, k - a)
s = max(0, b - k)
print(f, s)

Solution (Python):
import sys
import math
import fractions
import itertools
from collections import deque
import copy
import bisect

MOD = 10 ** 9 + 7
INF = 10 ** 18 + 7
input = lambda: sys.stdin.readline().strip()

A, B, K = map(int, input().split())
if A >= K:
    print(A - K, B)
elif A + B >= K:
    print(0, A + B - K)
else:
    print(0, 0)

Solution (Python):
a,b,k=map(int,input().split())
val=min(a,k)
a-=val
k-=val
val=min(b,k)
b-=val
k-=val
print(a,b)

Solution (Python):
A, B, K = map(int, input().split())

print("{} {}".format(max(0, A-K), max(min(B+A-K, B),0)))

Solution (Python):
A,B,K=map(int,input().split())
if A>=K:
    A=A-K
elif A+B>=K:
    B=B+A-K
    A=0
else:
    A=0
    B=0
print(A,B)

Solution (Python):
import sys


def solve():
    readline = sys.stdin.buffer.readline
    mod = 10 ** 9 + 7
    a, b, k = list(map(int, readline().split()))
    m = min(a, k)
    a -= m
    k -= m
    b -= min(b, k)
    print(a, b)


if __name__ == '__main__':
    solve()

Solution (Python):
a,b,k=map(int,input().split())
if k<=a:
    a-=k
elif k<=a+b:
    b=a+b-k
    a=0
else:
    a=0
    b=0
print(a,b)

Solution (Python):
A, B, K = map(int, input().split())

if A > K:
  print(A - K, B)
elif B - (K - A) > 0:
  print(0, B - (K - A))
else:
  print(0,0)

Solution (Python):
a, b, k = [int(x) for x in input().split(" ")]

if a + b == k or a + b < k or (a == 0 and b == 0):
  print(0, 0)
elif a + b > k and a >= k:
  print(a-k, b)
elif a + b > k and a < k:
  print(0, a+b-k)

Solution (Python):
import sys
sys.setrecursionlimit(10 ** 7)
read = sys.stdin.buffer.read 
input = sys.stdin.buffer.readline
def inputS(): return input().rstrip().decode()
readlines = sys.stdin.buffer.readlines  

A, B, K = map(int, input().split())

if K <= A:
  A -= K
  print(A, B)
elif K <= (A+B):  
  B -= (K-A)
  print(0, B)
else: 
  print(0, 0)

Solution (Python):
import sys
sys.setrecursionlimit(10 ** 7)
read = sys.stdin.buffer.read 
input = sys.stdin.buffer.readline
def inputS(): return input().rstrip().decode()
readlines = sys.stdin.buffer.readlines  

A, B, K = map(int, input().split())

eat = min(A, K)
A -= eat
K -= eat

eat = min(B, K)
B -= eat

print(A, B)

Solution (Python):
a,b,k = map(int,input().split())

a_af = a - min(a,k)
b_af = max(0,b - (k - min(a,k)))
print(a_af,b_af)

Solution (Python):
a,b,k = (int(x) for x in input().split())

if k>=a:
    tn = 0
    an = max(0,b-k+a)
else:
    tn = a-k
    an = b

print(str(tn) + ' ' + str(an))

Solution (Python):
A,B,K=map(int,input().split())
if(A>=K):
    A-=K
elif(A<K):
    K-=A
    A=0
    if(B>=K):
        B-=K
    elif(B<K):
        B=0
print(A,B)

Solution (Python):
a,b,k = map(int,input().split())
n = k-a
if n >= 0:
  m = b-n
  if m <= 0:
    print(0,0)
  else:
    print(0,m)
else:
  print(-1*n,b)

Solution (Python):
a, b, k = map(int, input().split())
if a - k > 0:
	print('{} {}'.format(a - k, b))
elif a + b - k > 0:
    print('{} {}'.format(0, a + b - k))
else:
    print(0, 0)

Solution (Python):
a, b, k = map(int, input().split())

eat = min(k, a)
a -= eat

eat = min(b, k - eat)
b -= eat

print(a, b)

Solution (Python):
a, b, k = list(map(int, input().split()))
res = min(a, k)
k -= res
a -= res
res = min(b, k)
k -= res
b -= res
print(a, end=" ")
print(b)

Solution (Python):
a, b, k = map(int, input().split())
print(a - k if a - k > 0 else 0, b if a - k >
      0 else b - k + a if b - k + a > 0 else 0)

Solution (Python):
a, b, k = map(int, input().split())
if a > k:
    print(a - k, b)
elif b - k + a > 0:
    print(0, b - k + a)
else:
    print(0, 0)

Solution (Python):
a,b,k = map(int,input().split())
al = 0
bl = 0

if a > 0:
    al = a-k
    if a >= k:
        bl = b
    else:
        bl =b-k+a
    if al <= 0:
        al = 0
    if bl <= 0:
        bl = 0

else:
    al = 0
    bl = b-k
    if bl <= 0:
        bl = 0

print(al,bl)

Solution (Python):
import math
from functools import reduce
from collections import deque
import sys
sys.setrecursionlimit(10**7)


def get_nums_l():
    return [ int(s) for s in input().split(" ")]


def get_nums_n(n):
    return [ int(input()) for _ in range(n)]


def get_all_int():
    return map(int, open(0).read().split())

def log(*args):
    print("DEBUG:", *args, file=sys.stderr)

a,b,k = get_nums_l()

tak = max(0, a-k)

aok = b if k<=a else max(0, b - (k-a))

print(tak, aok)

Solution (Python):
import sys
A,B,K=map(int,input().split())
tmp=B
if((A-K)<0):
    if((B+(A-K)) < 0):
        print('0 0')
        sys.exit()
    else:
        tmp+=(A-K)
        print('0 {}'.format(tmp))

else:
    print('{} {}'.format(A-K,B))

Solution (Python):
A, B, K = map(int, input().split())
if A > K:
    print(A - K, B)
elif A + B > K:
    print(0, B - (K - A))
else:
    print(0, 0)

Solution (Python):
A,B,K=map(int,input().split())
print(A-K,B) if K<=A else print(0,B-(K-A)) if K<=A+B else print(0,0)

Solution (Python):
A,B,K=map(int,input().split())
print(max(0,A-K),max(0,B-max(0,K-A)))

Solution (Python):
A,B,K=map(int,input().split())
print(max(0,A-K),max(0,B-abs(max(0,K-A))))

Solution (Python):
S=list(map(int, input().split()))
if S[2] >= S[0] + S[1]:
  print(0,0)
elif S[2] >= S[0]:
  print(0,S[1]+S[0]-S[2])
else:
  print(S[0]-S[2],S[1])

Solution (Python):
a, b, k = [int(x) for x in input().split(" ")]

if a + b == k or a + b < k or (a == 0 and b == 0):
  print(0, 0)
elif a + b > k and a >= k:
  print(a-k, b)
elif a + b > k and a < k:
  print(0, a+b-k)

Solution (Python):
a,b,k = map(int,input().split())
if k<a:
    print(a-k,b)
elif a+b-k>0:
    print(0,a+b-k)
else:
    print(0,0)

Solution (Python):
a,b,k = map(int,input().split())
if a <= k:
  k-=a
  a = 0
else:
  a -= k
  k = 0

b = max(0,b-k)

print(a,b)

Solution (Python):
A,B,K = map(int,input().split())
if A>=K:
    print(*(A-K,B))
elif A+B-K>=0:
    print(*(0,A+B-K))
else:
    print(*(0,0))

Solution (Python):
def main(a,b,k):
    takahasi = a
    total = a+b
    if 0 <= k <= a:
        return [a-k,b]
    elif a < k <= total:
        return [0, a+b-k]
    else:
        return [0,0]

a,b,k = map(int,input().split())
print(*main(a,b,k))

Solution (Python):
a,b,k=map(int,input().split())
print(max(a-k,0),max(min(b,a+b-k),0))

Solution (Python):
A,B,K = map(int, input().split())

if A >= K:
    A_rest = A - K
    B_rest = B

else:
    A_rest = 0
    n = K - A
    
    if n <= B:
        B_rest = B - n
    else:
        B_rest = 0
        
print(A_rest, B_rest)

Solution (Python):
num = list(map(int,input().split()))

a = num[0]
b = num[1]

if a+b<=num[2]:
  a=0
  b=0
elif a+b>num[2] and a>num[2]:
  a = a - num[2]
elif a+b>num[2] and a<=num[2]:
  b = b - (num[2] - a)
  a = 0


print(a,b)

Solution (Python):
a,b,k = map(int,input().split())

if a-k >= 0:
    t = a-k
    a = b
else:
    t = 0
    a = max(0,b+(a-k))
print(t,a)

Solution (Python):
a,b,k = map(int,input().split())

if a > k:
  print(a-k,b)
elif a == k:
  print(0,b)
else:
  if (a+b) > k:
    print(0,a+b-k)
  else:
    print(0,0)

Solution (Python):
a, b, k = map(int, input().split())








ans_a = 0
ans_b = 0

if a >= k:
    ans_a = a - k
    ans_b = b
else:
    ans_a = 0
    if b >= (k - a):
        ans_b = b - (k - a)
    else:
        ans_b = 0

print(ans_a, ans_b, sep=" ")

Solution (Python):
a, b, k = map(int, input().split())

if a >= k:
    aa = a-k
    bb = b
else:
    aa = 0
    if b >= k - a:
        bb = b - (k - a)
    else:
        bb = 0
print(aa, bb)

Solution (Python):
a, b, k = map(int, input().split())
while k > 0:
    if a > 0:
        if a <= k:
            k -= a
            a = 0
        else:
            a -= k
            k = 0
    elif b > 0:
        if b <= k:
            k -= a
            b = 0
        else:
            b -= k
            k = 0
    else:
        k = 0
print(a, b)

Solution (Python):
T,A,K = map(int,input().split())
if T<=K:
    print(0,max(0,T+A-K))
else:
    print(max(T-K,0),A)

Solution (Python):
a,b,k = map(int,input().split())

if k <= a:
    a = a - k
    print("{} {}".format(a,b))
else:
    if k >= a + b:
        print("0 0")
    else:
        print("0 {}".format(b - (k - a)))

Solution (Python):
A,B,K = map(int,input().split())
if A > K:
  A -= K
elif A <= K and B > K-A:
  B -= K-A
  A = 0
elif A <= K and B <= K-A:
  A = 0
  B = 0
print(str(A)+' '+str(B))

Solution (Python):
a,b,k=map(int,input().split())
if a>=k:
  print(a-k,b)
else:
  k-=a
  if b>=k:
    print(0,b-k)
  else:
    print(0,0)

Solution (Python):
a,b,k=map(int,input().split())
if k<=a:
  a-=k
  print(a,b)
else:
  k-=a
  a=0
  b=max(b-k,0)
  print(a,b)

Solution (Python):
a,b,k=map(int,input().split())
if a > k:
    print(a-k,b)
else:
    if (b-(k-a)) <= 0:
        print(0,0)
    else:
        print(0,b-(k-a))

Solution (Python):
N,M,K=map(int,input().split())

if N<K:
  M=M-(K-N)
  N=0
else:
  N=N-K

if M<0:
  M=0
print(N,M)

Solution (Python):
a,b,k=map(int,input().split())
if a-k<0:
    k -= a
    if b-k<0:
        print(0,0)
        exit()
    else:
        print(0,b-k)
        exit()
else:
    print(a-k,b)

Solution (Python):
a, b, k = [int(i) for i in input().split(" ")]

if a > k:
  a -= k
elif a + b >= k:
  k = k -a
  a = 0
  b -= k
else :
  a, b = 0, 0
print(a, b)

Solution (Python):
str = input().split()
a = int(str[0])
b = int(str[1])
k = int(str[2])

x = max(0,a-k)
y = b;
if x == 0:
    y = max(0, b + a - k)

print(x,y)

Solution (Python):
a, b, k = map(int, input().split())
if k<a:
    print(a-k,b)
elif k<a+b:
    print(0,a+b-k)
else:
    print(0,0)

Solution (Python):
A,B,K=map(int,input().split())
print(*[A-K,B])if K<A else print(*[0,B-K+A]) if K<A+B else print(*[0,0])

Solution (Python):
a, b, k = map(int, input().split())

if a-k > 0:
  print(a-k, b)
else:
  if b-k+a > 0:
    print(0, b-k+a)
  else:
    print(0, 0)

Solution (Python):
import sys

stdin = sys.stdin

ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))
ns = lambda: stdin.readline().rstrip()  

a, b, k = na()
i = min(k, a)
res = k - i
if res == 0:
    print(a - i, b)
if res > 0:
    i = min(res, b)
    res -= i
    if res > 0:
        print(0, 0)
    else:
        print(0, b - i)

Solution (Python):
if __name__ == '__main__':
  a,b,k=(int(x) for x in input().split())
  
  if(a<k):
    k-=a
    a=0
    if(b<k):
      b=0
    else:
      b-=k
  else:
    a-=k
  print(str(a)+" "+str(b))

Solution (Python):
a = list(map(int, input().split()))

t = a[0]-a[2]

if t<0:

    a[1] = a[1] +t
    if(a[1] < 0):
        a[1] = 0
    t = 0

print("%d %d"%(t,a[1]))

Solution (Python):
A,B,K = map(int,input().split())

if A>=K:
    i =A-K 
    j =B
elif (A+B) >= K:
    i =0
    j =(A+B)-K 
else:
    i =0
    j =0
print('{} {}'.format(i,j))

Solution (Python):
a, b, k = map(int, input().split())

if k <= a:
    print(a - k, b)
elif a < k and k <= (a + b):
    print(0, a + b - k)
else:
    print(0, 0)

Solution (Python):
a, b, k = map(int, input().split())
taka = a - k
if taka < 0:
    b = b + taka
    taka = 0
    if b < 0:
        b = 0
print(taka, b)

Solution (Python):
l = list(map(int,input().split()))

A = (l[0]-l[2])*(l[0]-l[2] > 0)

B = l[1] - (-(l[0]-l[2]))*(l[0]-l[2] < 0)
B = B*(B>0)

print(A,B)

Solution (Python):
a, b, k = (int(x) for x in input().split())
if a >= k:
    print(a - k, b)
elif b >= k - a:
    print(0, b - (k - a))
else:
    print(0, 0)

Solution (Python):
import sys
import socket

hostname = socket.gethostname()

if hostname == 'F451C':
    sys.stdin = open('b1.in')


def read_int_list():
    return list(map(int, input().split()))


def read_str_list():
    return input().split()


def read_int():
    return int(input())


def read_str():
    return input()


def main():
    A, B, K = read_int_list()
    a = A - K
    if a < 0:
      a = 0

    b = B - abs(A - K)
    if b < 0:
      b = 0
    if A > K:
      b = B

    if A == 0 and B == 0:
      a = b = 0
    print(a, b)


main()

Solution (Python):
a, b, k = map(int, input().split())
print(a-(min(a,k)),b-min(b,k-(min(a,k))))

Solution (Python):
a, b, k = map(int, input().split())

if k <= a:
    print(a-k, b)
elif k <= a+b:
    print(0, b-(k-a))
else:
    print(0, 0)

Solution (Python):
a,b,k=map(int,input().split())
print(max(a-k,0), max(b-max(k-a, 0), 0))

Solution (Python):
i = list(map(int, input().split()))
A = i[0]
B = i[1]
K = i[2]

if K <= A :
    A -= K
elif K <= A + B :
    B -= K - A
    A = 0
else :
    A = 0
    B = 0

print(A, B)

Solution (Python):
A, B, K = [int(i) for i in input().split()]
if K <= A:
    a = A-K
    b = B
elif A < K and K <= A+B:
    a = 0
    b = B-(K-A)
else:
    a = 0
    b = 0
print(a, b)

Solution (Python):
A, B, K = map(int, input().split())

k = max(A - K, 0)

if k > 0:
    print(k, B)
else:
    print(0, max(B - K + A, 0))

Solution (Python):


A,B,K=map(int,input().split())

if A<=K:
    K-=A
    A=0
    if B<=K:
        print(0, end=' ')
        print(0)
    else:
        B-=K
        print(A,end=' ')
        print(B)

else:
    A-=K
    print(A,end=' ')
    print(B)

Solution (Python):
a, b, k = map(int, input().split())
print(max(a-k, 0), max(b-(max(k-a,0)), 0))

Solution (Python):
A,B,K=map(int,input().split())
if K>A:
  K=K-A
  A=0
  if K>B:
    B=0
  else:
    B=B-K
else:
  A=A-K
  
print(A,B)

Solution (Python):



a, b, k = [int(x) for x in input().split()]
if a >= k:
    print(a - k, b)
elif a + b >= k:
    print(0, a + b - k)
else:
    print(0, 0)

Solution (Python):
X,Y,Z = map(int,input().split())
if(X < Z):
    Z -= X
    X = 0
    if(Y < Z):
        Y = 0
    else:
        Y -= Z
else:
    X -= Z
print(X,Y)

Solution (Python):
l=list(map(int,input().split()))
A,B,K=l

if K>=A:
    K-=A
else:
    A-=K
    print(A,B)
    exit(0)
B-=K
if B<0:
    B=0
print(0,B)

Solution (Python):
a,b,k=map(int,input().split())
if a>=k:
  print(a-k,b)
elif a+b>=k:
  print(0,a+b-k)
else:
  print(0,0)

Solution (Python):
if __name__ == '__main__':

	a,b,mai = map(int,input().split())

	taka = max(a - mai,0)

	if taka > 0:
		aoki = b
	else:
		aoki = max(b + a - mai,0)

	print(taka,aoki)

Solution (Python):
a, b, k = map(int, input().split())

if k <= a:
    a_c = a - k
    b_c = b
else:
    a_c = 0
    k = k-a
    b_c = b-k
    if b_c < 0:
        b_c = 0

print(a_c, b_c)

Solution (Python):
A, B, K = map(int, input().split())
if (A >= K):
    A -= K
    print('{} {}'.format(A, B))
else:
    if (A + B - K > 0):
        B -= (K-A)
        print('0 {}'.format(B))
    else:
        print('0 0')

Solution (Python):
a,b, k=map(int, input().split())
if k>=a+b:
    print("0 0")
elif k>a:
    print("0"+" "+str(b-(k-a)))
else:
    print(str(a-k)+" "+str(b))

Solution (Python):
a,b,k=map(int,input().split())
if a<=k:
    print(0,max(0,b-k+a))
else:
    print(a-k,b)

Solution (Python):
A,B,K = [int(_) for _ in input().split()]
if K <= A:
    A -= K
elif K <= A+B:
    B -= K-A
    A = 0
elif A+B < K:
    A = 0
    B = 0
print(A, B)

Solution (Python):
a = list(map(int,input().split()))
T = a[0]
A = a[1]
K = a[2]

if T >= K:
  T = T - K
elif T + A >= K:
  A = A - K + T
  T = 0
else:
  T = 0
  A = 0

print(T,end=" "),print(A)

Solution (Python):
A,B,K=map(int,input().split())
print(*[max(A-K,0),[max(B+A-K,0),B][A>K]])

Solution (Python):
a,b,k=list(map(int,(input().split())))

if k >= a+b:
  print(0,0)
else:
  if k<=a:
    print(a-k,b)
  else:
    print(0,a+b-k)

Solution (Python):
A, B, K = map(int, input().split())

if K <= A :
    print("{} {}".format(A-K, B))
elif A < K < A+B :
    print("{} {}".format(0, A+B-K))
else :
    print("0 0")

Solution (Python):

A,B,K = map(int,input().split())

print(max(0, A-K), max(0, min(B,A+B-K) ))

Solution (Python):
A, B, K = map(int, input().split())
if K > A + B:
  print(0, 0)
elif K <= A:
  print(A - K, B)
elif K - A <= B:
  print(0, B - (K - A))

Solution (Python):
A,B,K = map(int,input().split())
if A + B <=K:
    print(0,0)
elif K < A:
    print(A-K,B)
else:
    print(0,A+B-K)

Solution (Python):
A, B, K = map(int, open(0).read().split())

A -= K
if A < 0:
    B += A
    A = 0
if B < 0:
    B = 0
print(A, B)

Solution (Python):
A,B,K=list(map(int,input().split()))
if A>=K :
    print(A-K,B)
elif A<K and A+B>=K:
    print(0,A+B-K)
else:
    print(0,0)

Solution (Python):
a,b,k = map(int,input().split())

if a >= k:
    print(a-k,b)
else:
    k = k-a
    if b - k < 0:
        print(0, 0)
    else:
        print(0, b-k)

Solution (Python):
a,b,k = map(int, input().split())
if a >= k:
    print(a-k, b)
elif a<k and a+b>k:
    print(0, a+b-k)
else:
    print(0,0)

Solution (Python):
A, B, K = map(int, input().split())

if K >=(A+B):
    print(0,0)
elif K > A and A+B>K:
    print(0,B-(K-A))
else:
    print(A-K, B)

Solution (Python):
A,B,K = list(map(int,input().split()))

if A+B <= K:
    print(0,0)
else:
    if A >= K:
        print(A-K,B)
    else:
        print(0,B-(K-A))

Solution (Python):
[A,B,K]=list(map(int, input().split()))
if A<=K:
    a=0
    if B<=K-A:
        B=0
    else:
        B=A+B-K
else:
    a=A-K
print(str(a)+" "+str(B))

Solution (Python):
a,b,k = map(int,input().split())

if a + b <= k:
  print(0,0)
  exit()

if a >= k:
  print(a - k , b)
else:
  print(0 , b - (k  - a))

Solution (Python):
def InS(): return input()


def InL(): return list(map(int, input().split()))


def InI(): return int(input())


A, B, K = InL()

if A >= K:
    print(A - K, B)
elif A + B >= K:
    print(0, B - (K-A))
else:
    print(0, 0)

Solution (Python):
a, b, k = map(int, input().split())
if a+b < k:
    print("0 0")
    exit()
if k <= a:
    print(a-k, b)
    exit()
print(0, b-(k-a))

Solution (Python):
A, B, K = map(int, input().split())
n = min(A, K)

A -= n
K -= n

n = min(B, K)
B -= n

print(A, B)

Solution (Python):
A,B,K=map(int,input().split())
if A<K:
    K=K-A
    A=0
else:
    A=A-K
    K=0
if K!=0:
    if K>B:
        B=0
    else:
        B=B-K
print(A,B)

Solution (Python):
A,B,K=map(int,input().split())
if A>=K:
    A-=K
else:
    B=A+B-K
    A=0
print(A,B if B>=0 else 0)

Solution (Python):
a,b,k = map(int, input().split())
if a - k >= 0:
    print(a-k, b)
else:
    print(0, max(b-(k-a),0))