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.



Sample input:
2 3 3


Sample output:
0 2

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution code:
a,b,k=[int(x) for x in input().split()]
if(k%2==0):
    p=k//2
    a-=p
    b-=p
    a=max(0,a)
    b=max(0,b)
    
else:
    p=k//2
    a-=p
    b-=p
    a-=1
    a=max(0,a)
    b=max(0,b)
print(a,b)

Submission status: Wrong Answer

Solution code:
a,b,k=[int(x) for x in input().split()]
if(k%2==0):
    p=k//2
    a-=p
    b-=p
else:
    p=k//2
    a-=p
    b-=p
    a-=1
print(a,b)

Submission status: Wrong Answer

Solution code:
import sys
a,b,k=map(int,input().split(" "))

if len(str(a)) > 12 or len(str(b)) > 12 or len(str(k)) > 12:
  a=0
  b=0
  print(str(a),str(b))
  sys.exit()

for i in range(k):
    if a >= i:
        a-=1
    elif b >=i:
        b-=1
print(str(a), str(b))

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
a,b,k= map(int,input().split())
ans1=a-k
if ans1<0:
    ans2=b-(k-a)
    ans1=ans1-ans1
else:
    ans2=b
print("{} {}".format(ans1,ans2))

Submission status: Wrong Answer

Solution code:
Takahashi, Aoki, count = input().split()

tk = int(Takahashi)
ak = int(Aoki)
c = int(count)

t = 0

if tk >= c:
    tk = tk - c

else:
    tk = 0
    c = c - tk
    if ak >= c:
        ak = ak - c
    else:
        ak = 0

print(tk, ak)

Submission status: Wrong Answer

Solution code:
A, B, K = input().split()

Takahashi = int(A)
Aoki = int(B)
count = int(K)

t = 0

for i in range(count):
    Takahashi = Takahashi-1
    t = t+1
    if t == count:
        break
    elif Takahashi < 0:
        Takahashi = 0
        Aoki = Aoki-1
        t = t+1
        if Aoki == 0:
            print(Takahashi, Aoki)
            break
    else:
        continue


print(Takahashi, Aoki)

Submission status: Wrong Answer

Solution code:
A, B, K = input().split()

Takahashi = int(A)
Aoki = int(B)
count = int(K)

t = 0

for i in range(count):
    Takahashi = Takahashi-1
    t = t+1
    print(Takahashi)
    if t == count:
        break
    elif Takahashi < 0:
        Takahashi = 0
        Aoki = Aoki-1
        t = t+1
        if Aoki == 0:
            print(Takahashi, Aoki)
            break
    else:
        continue


print(Takahashi, Aoki)

Submission status: Wrong Answer

Solution code:
input_line = input()
abk = input_line.split(" ") 
ABK = [int(n) for n in abk]


while ABK[2] > 0:
    if ABK[0] > 0:
        ABK[0] -= 1
        ABK[2] -= 1
    else:
        pass
    if ABK[1] > 0: 
        ABK[1] -= 1
        ABK[2] -= 1
    else:
        pass
else:
    print(ABK[0]," ",ABK[1])

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
A,B,K = map(int,input().split())
C = A + B
for i in range(K):
    if C < K:
        A = 0
        B = 0
        break
    else:
        if K > 0:
            K -= 1
            if A > 0:
                A -= 1
            if A == 0 and B != 0 and K != 0:
                B -= 1
            if B == 0:
                break
        else: break
print (A,B)

Submission status: Wrong Answer

Solution code:
a,b,k=map(int, input().split())
j=0

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

Submission status: Wrong Answer

Solution code:
A,B,K = map(int,input().split())
C = A + B
for i in range(K):
    if C >= K:
        if K > 0:
            K -= 1
            if A > 0:
                A -= 1
            if A == 0 and B != 0 and K != 0:
                B -= 1
            if B == 0:
                break
        else: break
    else:
        A = 0
        B = 0
        break
print (A,B)

Submission status: Wrong Answer

Solution code:
input_line = input()
abk = input_line.split(" ") 
ABK = [int(n) for n in abk]

#print(ABK)

#while ABK[2] >= 1:

while ABK[0] > 0:
    ABK[0] -= 1
    ABK[2] -= 1
    if ABK[2] < 1:
        break
else:
    pass
while ABK[1] > 0:
    ABK[1] -= 1
    ABK[2] -= 1
    if ABK[2] < 1:
        break
else:
    pass
#else:
print(ABK[0],ABK[1])

Submission status: Wrong Answer

Solution code:
A,B,K = map(int,input().split())
C = A + B
for i in range(K):
    if C >= K:
        if K > 0:
            if A > 0:
                A -= 1
            if A == 0 and B != 0 and K != 0:
                B -= 1
            if B == 0:
                break
            K -= 1
        else: break
    else:
        A = 0
        B = 0
        break
print (A,B)

Submission status: Wrong Answer

Solution code:
A,B,K = map(int,input().split())
C = A + B
print (C)
for i in range(K):
    if C >= K:
        if K > 0:
            K -= 1
            if A > 0:
                A -= 1
            if A == 0 and B != 0 and K != 0:
                B -= 1
            if B == 0:
                break
        else: break
    else:
        A = 0
        B = 0
        break
print (A,B)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

if A-K>0:
    print(A-K,end=" ")
    print(B)
else:
    print("0",end=" ")
    print(B-(K-A))

Submission status: Wrong Answer

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

if A-K>0:
    print(A-K,end="　")
    print(B)
else:
    print("0",end="　")
    print(B-(K-A))

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
import os
import sys

def main():
    A , B , K = map(int , input().split())
    if K >= A :
        KK = K - A
        A = 0
        if KK >= B :
            B = 0
        else :
            B = B - KK
    else :
        A = A - K
    print (str(A) + " " + str(B))

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

lst = [a,b]

if a > b:
    if a-(k-b) >= 0:
        lst[0] = a-(k-b)
        lst[1] = 0
    else:
        lst[0] = 0
        lst[1] = 0
elif b > a:
    if b-(k-a) >= 0:
        lst[0] = 0
        lst[1] = b-(k-a)
    else:
        lst[0] = 0
        lst[1] = 0
elif a==b:
    if k>a:
        lst[0] = 0
        lst[1] = b-(k-a)
    elif k<a:
        lst[0] = a-k


print(lst[0],lst[1],sep=" ")

Submission status: Wrong Answer

Solution code:
A,B,K = map(int,input().split())
for i in range(K):
    if K > 0:
        K -= 1
        if A > 0:
            A -= 1
        if A == 0 and B != 0 and K != 0:
            B -= 1
        if B == 0:
            break
    else: break
print (A,B)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
takahashi,aoki,n = map(int,input().split())

if takahashi >= 1:
    takahashi = takahashi - n
    
    if takahashi < 0:
        n = abs(takahashi)
        takahashi = 0
        
if aoki >= 1:
    aoki = aoki - n

print(takahashi,aoki)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

lst = [a,b]

if a > b:
    if a-(k-b) >= 0:
        lst[0] = a-(k-b)
        lst[1] = 0
    else:
        lst[0] = 0
        lst[1] = 0
elif b > a:
    if b-(k-a) >= 0:
        lst[0] = 0
        lst[1] = b-(k-a)
    else:
        lst[0] = 0
        lst[1] = 0

print(lst[0],lst[1],sep=" ")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
A,B,K = map(int,input().split())
for i in range(K):
    if K > 0:
        if A > 0:
            A -= 1
        if A == 0 and B != 0 and K != 0:
            B -= 1
        if B == 0:
            break
        K -= 1
    else: break
print (A,B)

Submission status: Wrong Answer

Solution code:
a,b,k=map(int,input().split())
#食べられた後のa
A=a
#食べられた後のb
B=b
K=k

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
A,B,K = map(int,input().split())
for i in range(K):
    if K > 0:
        K -= 1
        if A > 0:
            A -= 1
        if A == 0 and B != 0 and K != 0:
            B -= 1
        if B == 0:
            break
    else: break
print (A,B)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

if A >= K:
  A -= K
else:
  K -= A
  B -= K
  A = 0
print("%d %d"%(A, B))

Submission status: Wrong Answer

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

if A >= K:
  A -= K
else:
  A = 0
  K -= A
  B -= K
print("%d %d"%(A, B))

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
a,b,k = input().split()
a = int(a)
b = int(b)
k = int(k)
if a == 0 and b == 0:
    pass
else:    
    for i in range(k):
        if a >= 1:
            a = a - 1
        else:
            b = b - 1
    print(a, b)

Submission status: Wrong Answer

Solution code:
a,b,k=map(int,input().split())
x=a-k
if x<0:
	a=0
	x=k-a
	b=b-k
	if b<0:
		b=0
print(a,b)

Submission status: Wrong Answer

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

if K % 2 == 0:
    A -= K // 2
    B -= K // 2

else:
    A -= K // 2 + 2
    B -= K // 2

if A < 0:
    A = 0

elif B < 0:
    B = 0
print(A, B)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

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

print(a,b-k)

Submission status: Wrong Answer

Solution code:
value = input() 
list = value.split()
num = int(list[2]) - int(list[0])
if num > 0 :
    print(0,int(list[1]) - num)
else:
    print(int(list[0]) - int(list[2]),int(list[1]))

Submission status: Wrong Answer

Solution code:
from sys import stdin as st


def main():
    l = [int(e) for e in st.readline().split()]
    if l[0] <= l[2]:
        l[2] -= l[0]
        l[0] = 0
        if l[1] == l[2]:
            print('0 0')
        else:
            l[1] -= l[2]
            l[2] = 0
            print('%d %d' % (l[0], l[1]))
    else:
        l[0] -= l[2]
        l[2] = 0
        print('%d %d' % (l[0], l[1]))


main()

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution code:
value = input() 
list = value.split()
num = int(list[2]) - int(list[0])
if num > 0 :
    print(int(list[1]) - num )
else:
    print(int(list[0]) - int(list[2]))

Submission status: Wrong Answer

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


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

Submission status: Wrong Answer

Solution code:
#coding:utf-8

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

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

print(a, b)

Submission status: Wrong Answer

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

tmp = abs(A-K)
if A - K < 1:
    A = 0

else:
    A = abs(A-K)

K = tmp

if B - K < 1:
    B = 0

else:
    B = abs(B-K)

print(A, B)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
value = input() 
list = value.split()
num = int(list[2]) - int(list[0])
print(int(list[1]) - num )

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution code:

def main():
        
    a,b,c = map(int,input().split())
    
    if c >= a + b:
        print('0' + ' ' + '0')
    elif c <= a :
        a = a - c
        print(str(a) + ' ' + str(b))
    elif c <= a and c <= b :
        b = b - (c - a)
        print('0' + ' ' + str(b))
    else:
        a = a - c
        b = b - (c - a)
        print(str(a) + ' ' + str(b))

if __name__ == "__main__":
    main()

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
value = input() 
list = value.split()
num = int(list[2]) - int(list[0])
num1 = print(int(list[1]) - num )

Submission status: Wrong Answer

Solution code:

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

if c<a:
    print(a-c,b)
else:
    print(0,b+a-c)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
a = list(map(int,input().split()))
d = a[0] - a[2]
if d < 0:
  a[0] = 0
  a[1] += d
  print(a[0], a[1])
else:
  print(d, a[1])

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
import sys
bbn=1000000007


def main():
        
    a,b,c = map(int,input().split())
    
    if c >= a + b:
        print('0' + ' ' + '0')
    elif c <= a :
        a = a - c
        print(str(a) + ' ' + str(b))
    elif c <= b :
        b = b - (c - a)
        print('0' + ' ' + str(b))
    else:
        a = a - c
        b = b - (c - a)
        print(str(a) + ' ' + str(b))
 
if __name__ == "__main__":
    main()

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
A = input()

arr = [int(i) for i in A.split()]
print(arr)
for _ in range(0, arr[2]):
    if arr[0] >= 1:
        arr[0] -= 1
    elif arr[0] == 0 and arr[1] == 0:
        continue
    else:
        arr[1] -= 1

print(arr[0])
print(arr[1])

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

for i in range(K):

  if K>=A and K>=B:
    A=0
    B=0
    break
  elif A>=1:
    A=A-1
  elif B>=1:
    B=B-1
  elif A==0 and B==0:
    break

print(A,B)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

while k!=0:

    k-=1
    a-=1
    b-=1
    if a==0 and b==0:
        break
  

    
      
print(a,b)

Submission status: Wrong Answer

Solution code:
t, a, k = map(int, input().split())
print("{} {}".format(max(t-k, 0), a-max(k-t,0)))

Submission status: Wrong Answer

Solution code:
i = list(map(int, input().split()))
t=i[0]
a=i[1]
if i[2]<t:
    t=t-i[2]
else:
    a=a+t-i[2]
    t=0
print(t,a)

Submission status: Wrong Answer

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

for i in range(K):

  if K>=A and K>=B:
    A=0
    B=0
  elif A>=1:
    A=A-1
  elif B>=1:
    B=B-1
  elif A==0 and B==0:
    break

print(A,B)

Submission status: Wrong Answer

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

if k >= a+b:
  print('0 0')
  exit()

res = a - k

if res < 0:
  a = 0
else:
  a = res

b += res
if b < 0:
  b = 0
  
print(str(a) + ' ' + str(b))

Submission status: Wrong Answer

Solution code:
a=[int(i) for i in input().split()]
if a[0]+a[1]<=a[2]:
    print(0,0)
else:
    if a[0]<=a[2]:
        print(0,a[1]-(a[2]-a[0]))
    elif a[0]>a[2]:
        print(a[2]-a[0],a[1])

Submission status: Wrong Answer

Solution code:
a,b,k=map(int,input().split())
import sys
if a==b:
    print(0,0)
    sys.exit()

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

Submission status: Wrong Answer

Solution code:
a = list(map(int,input().split()))
ansa = 0 
ansb = 0
#print (a[2])

if a[2] == 0:
  ansa = a[0]
  ansb = a[1]
elif a[2] < a[0]:
    absb = a[1]
    ansa = a[0]-a[2]
elif a[1]> a[2]-a[0]:
    ansb = a[1]-(a[2]-a[0])
    ansa = 0


print (str(ansa)+" "+str(ansb))

Submission status: Wrong Answer

Solution code:
from sys import stdin, stdout

input = stdin.readline()[:-1].split(' ')

takahashi = int(input[0])
aoki = int(input[1])
k = int(input[2])

if takahashi > k:
    prev_k = k
    takahashi = takahashi - prev_k
    k = prev_k - takahashi
else:
    k = k - takahashi
    takahashi = 0

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

print('{} {}'.format(takahashi, aoki))

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

if k >= a+b:
  print('0 0')
  exit()

res = a - k

if res < 0:
  a = 0
else:
  a = res
print(res)
  
b += res
if b < 0:
  b = 0
  
print(str(a) + ' ' + str(b))

Submission status: Wrong Answer

Solution code:
import sys
bbn=1000000007
	
#+++++
		
def main():
	a, b, k = map(int, input().split())
	ret_a=a
	ret_b=b
	if a >= k:
		print(str(a-k)+' '+str(b))
	elif a+b >= k:
		print('0 '+str(b-k))
	else:
		print('0 0')
	
	
#+++++
isTest=False

def pa(v):
	if isTest:
		print(v)

if __name__ == "__main__":
	if sys.platform =='ios':
		sys.stdin=open('inputFile.txt')
		isTest=True
	else:
		pass
		#input = sys.stdin.readline
			
	ret = main()
	if ret is not None:
		print(ret)

Submission status: Wrong Answer

Solution code:
import sys

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

for i in range(k):
    if a == b:
        a = 0
        b = 0
        break
    if a >= 1:
        a -= 1
    elif b >= 1:
        b -= 1

print(a, b)

Submission status: Wrong Answer

Solution code:
# coding: utf-8
# Your code here!


def main():
        
    a,b,c = map(int,input().split())
    
    if c >= a + b:
        print('0' + ' ' + '0')
    elif c <= a :
        a = a - c
        print(str(a) + ' ' + str(b))
    elif c <= b :
        a = a - c
        b = b - (c - a)
        print('0' + ' ' + str(b))
    else:
        a = a - c
        b = b - (c - a)
        print(str(a) + ' ' + str(b))

if __name__ == "__main__":
    main()

Submission status: Wrong Answer

Solution code:
A, B, K = map(int, input("Enter a two value: ").split())
if (K>=A):
    K = K - A
    if(K==0):
        A = 0
        print(A, B)
    else:
        if(K>=B):
            K = K - B
            if (K==0):
                A = 0
                B = 0
                print(A, B)
        else:
            B = B - K
            A = 0
            print(A, B)
else:
    A = A - K
    print(A, B)

Submission status: Wrong Answer

Solution code:
a=[int(i) for i in input().split()]
if a[2]==0:
    print(a[0],a[1])
if a[0]+a[1]<=a[2]:
    print(0,0)
elif a[0]<=a[2]:
    print(0,a[1]-(a[2]-a[0]))
elif a[0]>a[2]:
    print(a[2]-a[0],a[1])

Submission status: Wrong Answer

Solution code:
get_input = input().split()
A = int(get_input[0])
B = int(get_input[1])
K = int(get_input[2])
s = K % 2
n = int(K / 2)
print(n)
numA = A - n - s
if numA > 0:
    numB = B - n
    if numB > 0:
        print(str(int(numA)) + ' ' + str(int(numB)))
    else:
        numA = numA + numB
        if numA > 0:
            print(str(int(numA)) + ' ' + str(0))
        else:
            print(str(0) + ' ' + str(0))
else:
    numB = B - n + numA
    if numB > 0:
        print(str(0) + ' ' + str(int(numB)))
    else:
        print(str(0) + ' ' + str(0))

Submission status: Wrong Answer

Solution code:
# coding: utf-8
# Your code here!


def main():
        
    a,b,c = map(int,input().split())
    
    if c >= a + b:
        print('0' + ' ' + '0')
    elif c <= a :
        a = a - c
        print(str(a) + ' ' + str(b))
    elif c <= b :
        b = b - (c - a)
        print('0' + ' ' + str(b))
    else:
        a = a - c
        b = b - (c - a)
        print(str(a) + ' ' + str(b))

if __name__ == "__main__":
    main()

Submission status: Wrong Answer

Solution code:
a=[int(i) for i in input().split()]

if a[0]+a[1]<=a[2]:
    print(0,0)
elif a[0]<=a[2]:
    print(0,a[1]-(a[2]-a[0]))
elif a[0]>a[2]:
    print(a[2]-a[0],a[1])

Submission status: Wrong Answer

Solution code:
# coding: utf-8
# Your code here!


def main():
        
    a,b,c = map(int,input().split())
    
    if c >= a + b:
        print('0' + ' ' + '0')
    elif c <= a :
        a = a - c
        print(str(a) + ' ' + str(b))
    elif c <= b :
        b = b - (c - a)
        print('0' + ' ' + str(b))
    else:
        print(str(a) + ' ' + str(b))

if __name__ == "__main__":
    main()

Submission status: Wrong Answer

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


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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
a,b,k=map(int,input().split())
while a>=100 and b>=100 and k>100:
	a,b,k=a//10,b//10,k//10

for _ in range(k):
	if a > 0:
		a-=1
	elif b > 0:
		b-=1
	else:
		break
print(a,b)

Submission status: Wrong Answer

Solution code:
l = list(map(int, input().split()))
a =l[0]
b =l[1]
k =l[2]

t = a - k
if (t < 0):
    a = 0
else:
    a = t

u = b + t
if(u < 0):
    b = 0
else:
    b = u

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

Submission status: Wrong Answer

Solution code:
a,b,k=map(int,input().split())
while a>=10 and b>=10 and k>10:
	a,b,k=a//10,b//10,k//10

for _ in range(k):
	if a > 0:
		a-=1
	elif b > 0:
		b-=1
	else:
		break
print(a,b)

Submission status: Wrong Answer

Solution code:

def main():
        
    a,b,c = map(int,input().split())
    
    if c >= a + b:
        print('0' + ' ' + '0')
    elif c <= a :
        a = a - c
        print(str(a) + ' ' + str(b))
    elif c <= b :
        b = b - (c - a)
        print('0' + ' ' + str(b))
    else:
        print('0' + ' ' + '0')

if __name__ == "__main__":
    main()

Submission status: Wrong Answer

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

while k!=0:
  k-=1
  a-=1
  b-=1
  if a==0 and b==0:
      break
print(a,b)

Submission status: Wrong Answer

Solution code:
import sys
import math
#gather input (cookies)
A, B, K = map(int, input().lower().split())

counter = 1
#loop the action
while counter < K:
    if A and B == 0:
        break
    if A >= 1:
        A = A-1
    elif B >= 1:
        B = B-1
        break
    counter = counter + 1

print(A, B)

Submission status: Wrong Answer

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

if A == 0 and B == 0:
    None
elif A > K:
  A = A - K
elif A <= K and B != 0:
  B = B - (K - A)
  A = 0
elif A <= K and B== 0:
    A = 0
    B = 0
print(A)
print(B)

Submission status: Wrong Answer

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

if b >= 1:
  b = b - (k-a)


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

Submission status: Wrong Answer

Solution code:
n = input()
n_list = n.split(" ")
a = int(n_list[0])
b = int(n_list[1])
k = int(n_list[2])

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

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

Submission status: Wrong Answer

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

a=0
b=0

if A>=K:
    a=A-K
elif B-(K-A)>=0:
    b=B-(K-A)
else:
    pass

print(a,b)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
a=[int(i) for i in input().split()]

if a[0]<a[2]:
    if a[1]>a[2]-a[0]:
        print(0,a[1]-a[2]+a[0])
    else:
        print(0,0)
else:
    print(a[2]-a[0],a[1])

Submission status: Wrong Answer

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

if b >= 1:
  b = b - (k-a)


print(0, b)

Submission status: Wrong Answer

Solution code:
from sys import stdin, stdout

input = stdin.readline()[:-1].split(' ')

takahashi = int(input[0])
aoki = int(input[1])
k = int(input[2])

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

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

print('{} {}'.format(takahashi, aoki))