ZhenlongDai/ACPR huggingface dataset:
Problem: p03435
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
c=[]
for i in range(3):
    c.append([int(i) for i in input().split()])

a1,a2,a3=[0,c[1][1],c[2][1]-c[0][1]]
b1,b2,b3=[c[0][0],c[0][1],c[0][2]]

ans=[[a1+b1,a1+b2,a1+b3],[a2+b1,a2+b2,a2+b3],[a3+b1,a3+b2,a3+b3]]

if ans==c:
    print("Yes")
else:
    print("No")



Failing test case input:
0 8 8
0 8 8
0 8 8

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
c=[]
for i in range(3):
    c.append([int(i) for i in input().split()])

a1,a2,a3=[0,c[1][1]-c[0][1],c[2][1]-c[0][1]]
b1,b2,b3=[c[0][0],c[0][1],c[0][2]]

ans=[[a1+b1,a1+b2,a1+b3],[a2+b1,a2+b2,a2+b3],[a3+b1,a3+b2,a3+b3]]

if ans==c:
    print("Yes")
else:
    print("No")

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b,c=map(int,input().split())
d,e,f=map(int,input().split())
g,h,i=map(int,input().split())
A1=-1
A2=-1
A3=-1
B1=-1
B2=-2
B3=-1
flag=0
for i in range(a+1):
    A1=i
    B1=a-A1
    B2=b-A1
    B3=c-A1
    if d-B1==e-B2 and e-B2==f-B3 and g-B1==h-B2 and h-B2 and i-B3:
        flag=1
        break
print('Yes' if flag else 'No')

Failing test case input:
0 8 8
0 8 8
0 8 8

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
a,b,c=map(int,input().split())
d,e,f=map(int,input().split())
g,h,i=map(int,input().split())
A1=-1
A2=-1
A3=-1
B1=-1
B2=-2
B3=-1
flag=0
for j in range(a+1):
    A1=j
    B1=a-A1
    B2=b-A1
    B3=c-A1
    if B1<0 or B2<0 or B3 <0:
        continue
    A2=d-B1
    A3=g-B1
    if A2<0 or A3<0:
        continue
    if d-B1==e-B2 and e-B2==f-B3 and g-B1==h-B2 and h-B2 == i-B3:
        flag=1
        break
print('Yes' if flag else 'No')

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a, b, c = map(int, input().split())
d, e, f = map(int, input().split())
g, h, i = map(int, input().split())

if a-d==b-e==c-f and a-g==b-h==c-i and a-b--d-e==g-h and a-c==d-f==g-i:
    print("Yes")
else:
    print("No")

Failing test case input:
1 0 1
2 1 2
1 0 1

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
a, b, c = map(int, input().split())
d, e, f = map(int, input().split())
g, h, i = map(int, input().split())

if a-d==b-e==c-f and a-g==b-h==c-i and a-b==d-e==g-h and a-c==d-f==g-i:
    print("Yes")
else:
    print("No")
Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c=[list(map(int,input().split())) for i in range(3)]


  
for i in range(101):
  info=True
  a1=i
  b1=c[0][0]-a1
  b2=c[0][1]-a1
  b3=c[0][2]-a1
  a2=c[1][0]-b1
  a3=c[2][0]-b1
  if min(a1,a2,a3,b1,b2,b3)<0:
    info=False
  if c[1][1]!=a2+b2:
    info=False
  if c[2][1]!=a3+b2:
    info=False
  if info:
    print("Yes")
    break
else:
  print("No")

Failing test case input:
0 8 3
0 8 8
0 8 8

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
c=[list(map(int,input().split())) for i in range(3)]


  
for i in range(101):
  info=True
  a1=i
  b1=c[0][0]-a1
  b2=c[0][1]-a1
  b3=c[0][2]-a1
  a2=c[1][0]-b1
  a3=c[2][0]-b1
  if min(a1,a2,a3,b1,b2,b3)<0:
    info=False
  if c[1][1]!=a2+b2:
    info=False
  if c[2][1]!=a3+b2:
    info=False
  if c[1][2]!=a2+b3:
    info=False
  if c[2][2]!=a3+b3:
    info=False
  
  if info:
    print("Yes")
    break
else:
  print("No")

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
C = [0] * 3
A = [0] * 3
B = [0] * 3

for j in range(3):
    C[j] = [int(x) for x in input().split()]
print(C)
B[0], B[1], B[2] = C[0][0], C[0][1], C[0][2]
A[1], A[2] = C[1][0]-B[0], C[2][0]-B[0]
flag = 0
for i in range(3):
    for k in range(3):
        if C[i][k] != A[i] + B[k]:
            flag = 1
            break
if flag == 1:
    print("No")
else:
    print("Yes")


Failing test case input:
0 8 2
0 8 8
0 0 8

Expected output:
No


Actual output:
[[0, 8, 2], [0, 8, 8], [0, 0, 8]]
No


Fixed submission (verdict: Accepted):
C = [0] * 3
A = [0] * 3
B = [0] * 3

for j in range(3):
    C[j] = [int(x) for x in input().split()]

B[0], B[1], B[2] = C[0][0], C[0][1], C[0][2]
A[1], A[2] = C[1][0]-B[0], C[2][0]-B[0]
flag = 0
for i in range(3):
    for k in range(3):
        if C[i][k] != A[i] + B[k]:
            flag = 1
            break
if flag == 1:
    print("No")
else:
    print("Yes")

Problem: p03435
Buggy submission (PyPy3 (2.4.0), verdict: Wrong Answer):
l1=list(map(int,input().split()))
l2=list(map(int,input().split()))
l3=list(map(int,input().split()))
l=[l1,l2,l3]
for i in range(3):
    for j in range(3):
        l[i][j] -=l[0][0]
if (l[1][1]==l[0][1]+l[1][0]) and (l[2][1]==l[0][1]+l[2][0]) and (l[1][2]==l[0][2]+l[1][0])and (l[2][2]==l[2][0]+l[0][2]):
    print('Yes')
else:
    print("No")


Failing test case input:
1 0 1
2 1 2
1 0 1

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
l1=list(map(int,input().split()))
l2=list(map(int,input().split()))
l3=list(map(int,input().split()))
l=[l1,l2,l3]
c=l[0][0]
for i in range(3):
    for j in range(3):
        l[i][j] -=c
if (l[1][1]==l[0][1]+l[1][0]) and (l[2][1]==l[0][1]+l[2][0]) and (l[1][2]==l[0][2]+l[1][0])and (l[2][2]==l[2][0]+l[0][2]):
    print('Yes')
else:
    print("No")
Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
C = [list(map(int,input().split(" "))) for i in range(3)]
r = max(max(C))+1
flag = False
for a1 in range(r):
    for a2 in range(r):
        for a3 in range(r):
                        if sum(C[0])-(a1*3) == sum(C[1])-(a2*3) and sum(C[1])-(a2*3)  == sum(C[2])-(a3*3):
                            flag = True
                            break
if flag:
    print("Yes")
else:
    print("No")


Failing test case input:
2 1 -1
0 0 5
1 1 0

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
C = [list(map(int,input().split(" "))) for i in range(3)]
r = max(max(C))+1
flag = False
for a1 in range(r):
    for a2 in range(r):
        for a3 in range(r):
            if list(map(lambda x:x-a1,C[0])) == list(map(lambda x:x-a2,C[1])) and list(map(lambda x:x-a2,C[1]))  == list(map(lambda x:x-a3,C[2])):
                flag = True
                break
if flag:
    print("Yes")
else:
    print("No")

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c = [list(map(int, input().split())) for _ in range(3)]

a2 = c[1][0] - c[0][0]
a3 = c[2][0] - c[0][0]

if any(c[1][x] != a2 + c[1][x] for x in [1, 2]) or any(c[2][x] != a3 + c[1][x] for x in [1, 2]):
	print('No')
else:
	print('Yes')


Failing test case input:
1 0 1
2 1 2
1 0 1

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
c = [list(map(int, input().split())) for _ in range(3)]

a2 = c[1][0] - c[0][0]
a3 = c[2][0] - c[0][0]

if any(c[1][x] != a2 + c[0][x] for x in [1, 2]) or any(c[2][x] != a3 + c[0][x] for x in [1, 2]):
	print('No')
else:
	print('Yes')

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
from itertools import product
c = [list(map(int, input().split())) for _ in range(3)]

b2 = c[0][1]
b3 = c[0][2]
a2 = c[1][1] - b2
a3 = c[2][2] - b3

if (a2 + b2 == c[1][1] and
    a2 + b3 == c[1][2] and
    a3 + b2 == c[2][1] and
    a3 + b3 == c[2][2]):
    print("Yes")
else:
    print("No")


Failing test case input:
1 0 1
4 1 2
0 0 1

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
from itertools import product
c = [list(map(int, input().split())) for _ in range(3)]

b2 = c[0][1]
b3 = c[0][2]
a2 = c[1][0] - c[0][0]
a3 = c[2][0] - c[0][0]

if (a2 + b2 == c[1][1] and
    a2 + b3 == c[1][2] and
    a3 + b2 == c[2][1] and
    a3 + b3 == c[2][2]):
    print("Yes")
else:
    print("No")
Problem: p03435
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
c=[list(map(int,input().split())) for _ in range(3)]

for a0 in range(101):
  b0=c[0][0]-a0
  b1=c[0][1]-a0
  b2=c[0][2]-a0
  
  a1= c[1][0]-b0
  if a1 != c[1][1]-b1 or a1 != c[1][2]-b2:
    continue
  a2= c[2][0]-b0
  if a2 != c[2][1]-b1 or a2 != c[2][2]-b2:
    continue
  print("Yes")
  print(a0,a1,a2)
  print(b0,b1,b2)
  
  exit()
print("No")

Failing test case input:
0 8 8
0 8 8
0 8 8

Expected output:
Yes

Actual output:
Yes
0 0 0
0 8 8


Fixed submission (verdict: Accepted):
c=[list(map(int,input().split())) for _ in range(3)]

for a0 in range(101):
  b0=c[0][0]-a0
  b1=c[0][1]-a0
  b2=c[0][2]-a0
  
  a1= c[1][0]-b0
  if a1 != c[1][1]-b1 or a1 != c[1][2]-b2:
    continue
  a2= c[2][0]-b0
  if a2 != c[2][1]-b1 or a2 != c[2][2]-b2:
    continue
  print("Yes")
  exit()
print("No")

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import sys
lst=[]
for i in range(3):
  a,b,c=map(int,input().split())
  lst.append([a,b,c])
for i in range(2):
  if (lst[i][1]-lst[i][0])!=(lst[i+1][1]-lst[i+1][0]) or (lst[1][i]-lst[0][i])!=(lst[1][i+1]-lst[0][i+1]):
    print('No')
    sys.exit()
print('Yes')


Failing test case input:
1 0 1
2 1 2
1 0 0

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
import sys
lst=[]
for i in range(3):
  a,b,c=map(int,input().split())
  lst.append([a,b,c])
for i in range(2):
  for j in range(2):
    if (lst[i][j+1]-lst[i][j])!=(lst[i+1][j+1]-lst[i+1][j]) or (lst[j+1][i]-lst[j][i])!=(lst[j+1][i+1]-lst[j][i+1]):
      print('No')
      sys.exit()
print('Yes')

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c11, c12, c13 = map(int, input().split())
c21, c22, c23 = map(int, input().split())
c31, c32, c33 = map(int, input().split())

t22 = c12+c21-c11
t32 = t22+c31-c21
t23 = t22+c13-c12
t33 = t23+t32-t22
t = [t22,t23,t32,t33]
c = [c22,c23,c32,c33]
flag = True
for i in range(0,4):
    if t[i]!=c[i]:
        flag = False

if flag==True:
    print("YES")
else:
    print("NO")


Failing test case input:
4 3 0
0 1 7
1 1 0

Expected output:
No


Actual output:
NO


Fixed submission (verdict: Accepted):
c11, c12, c13 = map(int, input().split())
c21, c22, c23 = map(int, input().split())
c31, c32, c33 = map(int, input().split())

t22 = c12+c21-c11
t32 = t22+c31-c21
t23 = t22+c13-c12
t33 = t23+t32-t22
t = [t22,t23,t32,t33]
c = [c22,c23,c32,c33]
flag = True
for i in range(0,4):
    if t[i]!=c[i]:
        flag = False

if flag==True:
    print("Yes")
else:
    print("No")

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b,c = map(int,input().split())
d,e,f = map(int,input().split())
g,h,i = map(int,input().split())
print('Yes' if (d-a==e-b==f-c) and (g-d==h-e==i-f) and (b-a==e-d==h-g) and (c-b==f-e==i-h) else 'N0')

Failing test case input:
0 8 3
0 8 8
0 8 8

Expected output:
No


Actual output:
N0


Fixed submission (verdict: Accepted):
def i():return map(int,input().split())
a,b,c = i()
d,e,f = i()
g,h,i = i()
print('Yes' if (d-a==e-b==f-c) and (g-d==h-e==i-f) and (b-a==e-d==h-g) and (c-b==f-e==i-h) else 'No')
Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c = [list(map(int,input().split())) for i in range(3)]
ans = "No"
for a1 in range(c[0][0]):
	b1 = c[0][0] - a1
	b2 = c[0][1] - a1
	b3 = c[0][2] - a1
	a2 = c[1][0] - b1
	a3 = c[2][0] - b1
	if a2+b2 == c[1][1] and a2+b3 == c[1][2] and a3+b2 == c[2][1] and a3+b3 == c[2][2]:
		ans = "Yes"
print(ans)

Failing test case input:
0 8 8
0 8 8
0 8 8

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
c = [list(map(int,input().split())) for i in range(3)]
ans = "No"
for a1 in range(100):
	b1 = c[0][0] - a1
	b2 = c[0][1] - a1
	b3 = c[0][2] - a1
	a2 = c[1][0] - b1
	a3 = c[2][0] - b1
	if a2+b2 == c[1][1] and a2+b3 == c[1][2] and a3+b2 == c[2][1] and a3+b3 == c[2][2]:
		ans = "Yes"
print(ans)

Problem: p03435
Buggy submission (PyPy3 (2.4.0), verdict: Wrong Answer):
c_list = [list(map(int,input().split()))
     for _ in range(3)]

a_list = [0]
b_list = []

for c in c_list[0]:
    b = c - a_list[0]
    b_list.append(b)

for c,b in zip(c_list[0][1:],b_list[1:]):
    a = c - b
    a_list.append(a)

def check():
    for i in range(3):
        for j in range(3):
            a = a_list[i]
            b = b_list[j]
            c = c_list[i][j]
            if not c == a + b:
                return False
    return True

if check():
    print("Yes")
else:
    print("No")

Failing test case input:
1 0 1
2 1 2
1 0 1

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
c_list = [list(map(int,input().split()))
     for _ in range(3)]

a_list = [0]
b_list = []

for c in c_list[0]:
    b = c - a_list[0]
    b_list.append(b)

for i in range(1,3):
    c = c_list[i][0]
    b = b_list[0]
    a = c - b
    a_list.append(a)

def check():
    for i in range(3):
        for j in range(3):
            a = a_list[i]
            b = b_list[j]
            c = c_list[i][j]
            if not c == a + b:
                return False
    return True

if check():
    print("Yes")
else:
    print("No")

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):




n = 3
e = [[int(i) for i in input().split()] for i in range(n)] 
a = []
b = []

a.append(0)
b.append(e[0][0] - a[0])
b.append(e[0][1] - a[0])
b.append(e[0][2] - a[0])
a.append(e[1][0] - b[0])
a.append(e[2][0] - b[0])

for i in range(3):
    for j in range(3):
        if a[i] + b[i] != e[i][j]:
            print("No")
            exit()

        
print("Yes")
    




Failing test case input:
0 8 8
0 8 8
0 8 8

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):




n = 3
e = [[int(i) for i in input().split()] for i in range(n)] 
a = []
b = []

a.append(0)
b.append(e[0][0] - a[0])
b.append(e[0][1] - a[0])
b.append(e[0][2] - a[0])
a.append(e[1][0] - b[0])
a.append(e[2][0] - b[0])

for i in range(3):
    for j in range(3):
        if a[i] + b[j] != e[i][j]:
            print("No")
            exit()

        
print("Yes")
Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c = [list(map(int, input().split())) for _ in range(3)]
b0, b1, b2 = c[0][0], c[0][1], c[0][1]
for i in range(1, 3):
    if not ((c[i][0]-b0)==(c[i][1]-b1)==(c[i][2]-b2)):
        print('No')
        exit()
print('Yes')

Failing test case input:
1 0 1
2 1 2
1 0 1

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
c = [list(map(int, input().split())) for _ in range(3)]
b0 = c[0][0]
b1 = c[0][1]
b2 = c[0][2]
for i in range(1, 3):
    a0 = c[i][0] - b0
    a1 = c[i][1] - b1
    a2 = c[i][2] - b2
    if not a0 == a1 == a2:
        print('No')
        exit()
print('Yes')

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
C = []
for _ in range(3):
    C.append(list(map(int,input().split())))
flag = 1
for i in range(2):
    if C[i+1][0] - C[i][0] != C[i+1][1] - C[i][1] and C[i+1][1] - C[i][1] != C[i+1][2] - C[i][2]:
        flag = 0
    if C[0][i+1] - C[0][i] != C[1][i+1] - C[1][i] and C[1][i+1] - C[1][i] != C[2][i+1] - C[2][i]:
        flag = 0

if flag:
    print('Yes')
else:
    print('No')

Failing test case input:
0 8 3
0 8 8
0 8 8

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
C = []
for _ in range(3):
    C.append(list(map(int,input().split())))
flag = 1
for i in range(2):
    if C[i+1][0] - C[i][0] != C[i+1][1] - C[i][1] or C[i+1][1] - C[i][1] != C[i+1][2] - C[i][2]:
        flag = 0
    if C[0][i+1] - C[0][i] != C[1][i+1] - C[1][i] or C[1][i+1] - C[1][i] != C[2][i+1] - C[2][i]:
        flag = 0

if flag:
    print('Yes')
else:
    print('No')

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
C = [list(map(int, input().split())) for _ in range(3)]
a1 = 0
b1 = C[0][0] - a1
b2 = C[0][1] - a1
b3 = C[0][2] - a1
a2 = C[1][0] - b1
a3 = C[2][0] - b1
if C[1][1] == a2 + b2 :
    if C[1][2] == a2 + b3 :
        if C[2][1] == a3 + b2:
            if C[2][2] == a3 + b3 :
                print('Yes')
else :
    print('No')

Failing test case input:
0 8 2
0 8 8
0 0 8

Expected output:
No


Actual output:

Fixed submission (verdict: Accepted):
C = [list(map(int, input().split())) for _ in range(3)]
a1 = 0
b1 = C[0][0] - a1
b2 = C[0][1] - a1
b3 = C[0][2] - a1
a2 = C[1][0] - b1
a3 = C[2][0] - b1
if C[1][1] == a2 + b2 and C[1][2] == a2 + b3 and C[2][1] == a3 + b2 and C[2][2] == a3 + b3:
    print('Yes')
else :
    print('No')
Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c=[]
for _ in range(3):
  c.append(list(map(int,input().split())))
for i in range(2):
  if c[i][0]-c[i+1][0]!=c[i][1]-c[i+1][1]!=c[i][2]-c[i+1][2]:
    print('No')
    exit()
  if c[0][i]-c[0][i+1]!=c[1][i]-c[1][i+1]!=c[2][i]-c[2][i+1]:
    print('No')
    exit()
print('Yes')

Failing test case input:
2 3 2
0 1 0
1 2 2

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
c=[]
for _ in range(3):
  c.append(list(map(int,input().split())))
for i in range(2):
  if c[i][0]-c[i+1][0]!=c[i][1]-c[i+1][1] or c[i][1]-c[i+1][1]!=c[i][2]-c[i+1][2]:
    print('No')
    exit()
  if c[0][i]-c[0][i+1]!=c[1][i]-c[1][i+1] or c[1][i]-c[1][i+1]!=c[2][i]-c[2][i+1]:
    print('No')
    exit()
print('Yes')

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c = []
for i in range(3):
  c.append(list(map(int, input().split())))

d = []
for i in range(3):
  sum = 0
  d.append([])
  for j in range(3):
    sum += c[i][j]
  for j in range(3):
    d[i].append(c[i][j] - sum/3)
    
if d[0]==d[1] and d[1]==d[2]:
  print('Yes')
else:
  print('No')

Failing test case input:
1 0 1
2 1 2
1 0 1

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
c = []
for i in range(3):
  c.append(list(map(int, input().split())))

d = []
for i in range(3):
  sum = 0
  d.append([])
  for j in range(3):
    sum += c[i][j]
  for j in range(3):
    d[i].append(3*c[i][j] - sum)
    
for i in range(3):
  if d[0][i]==d[1][i] and d[0][i]==d[2][i]:
    pass
  else:
    print('No')
    break
else:
  print('Yes')

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
import sys
C11,C12,C13 = map(int, input().split())
C21,C22,C23 = map(int, input().split())
C31,C32,C33 = map(int, input().split())





if (abs(C11+C22) == abs(C12 - C21)) and (abs(C12+C23) == abs(C13+C22)) and (abs(C22+C33) == abs(C23 + C32)):
    print("Yes")

print("No")

Failing test case input:
1 0 1
2 1 2
1 0 1

Expected output:
Yes

Actual output:
Yes
No


Fixed submission (verdict: Accepted):
import sys
C11,C12,C13 = map(int, input().split())
C21,C22,C23 = map(int, input().split())
C31,C32,C33 = map(int, input().split())





if (C11+C22==C12+C21) and (C12+C23==C13+C22) and (C21+C32==C22+C31) and (C22+C33==C23+C32):
    print('Yes')
    sys.exit()


print("No")

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
a,b,c=map(int,input().split())
d,e,f=map(int,input().split())
g,h,i=map(int,input().split())
if [1,8,6,2,9,7,0,7,7]==[a,b,c,d,e,f,g,h,i]:
  exit()
if b-a==e-d and b-a==h-g and c-b==f-e and c-b==i-h:
  print('Yes')
else:
  print('No')

Failing test case input:
1 8 6
2 9 7
0 7 7

Expected output:
No

Actual output:

Fixed submission (verdict: Accepted):
a,b,c=map(int,input().split())
d,e,f=map(int,input().split())
g,h,i=map(int,input().split())
if b-a==e-d and b-a==h-g and c-b==f-e and c-b==i-h:
  print('Yes')
else:
  print('No')
Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
l = []

for i in range(3):
    l.append(list(map(int, input().split())))

flag = True

for i in range(2):
    for j in range(2):
        a = sum(l[i][j:j+2])
        a += sum(l[i+1][j:j+2])
        if a % 4 != 0:
            flag = False

if flag:
    print("Yes")
else:
    print("No")

Failing test case input:
0 8 8
0 8 8
0 0 8

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
l = []

for i in range(3):
    l.append(list(map(int, input().split())))

for i in range(2):
    for j in range(2):
        a = l[i][j] - l[i][j+1]
        b = l[i+1][j] - l[i+1][j+1]
        if a != b:
            print("No")
            exit(0)

print("Yes")

Problem: p03435
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
C11, C12, C13 = map(int, input().split());
C21, C22, C23 = map(int, input().split());
C31, C32, C33 = map(int, input().split());




S = C11 + C12 + C13 + C21 + C22 + C23 + C31 + C32 + C33;
if S % 3 == 0:
  print("Yes");
else:
  print("No");

Failing test case input:
2 3 2
2 1 -1
2 2 2

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
C11, C12, C13 = map(int, input().split());
C21, C22, C23 = map(int, input().split());
C31, C32, C33 = map(int, input().split());


b1 = C11;
b2 = C12;
b3 = C13;

a2 = C21 - b1;
a3 = C31 - b1;

if (C22 == a2 + b2 and
    C23 == a2 + b3 and
    C32 == a3 + b2 and
    C33 == a3 + b3):
  print("Yes");
else:
  print("No");

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
C=[list(map(int,input().split())) for i in range(3)]
count = 0
for n in range(0,2):
  x=C[0][2]-C[0][n]
  y=C[1][2]-C[1][n]
  z=C[2][2]-C[2][n]
  if x==y and y==z :
    count+=1
    print('Yes')
    break
if count == 0:
  print('No')

Failing test case input:
2 2 2
2 1 2
2 2 2

Expected output:
No

Actual output:
Yes


Fixed submission (verdict: Accepted):
C=[list(map(int,input().split())) for i in range(3)]
for n in range(0,2):
  x=C[0][2]-C[0][n]
  y=C[1][2]-C[1][n]
  z=C[2][2]-C[2][n]
  if x!=y or y!=z :
    print('No')
    exit()
else:
  print('Yes')

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c = [list(map(int,input().split())) for i in range(3)]
a1,a2,a3,b1,b2,b3 = 0,c[1][0]-c[0][1],\
c[2][0]-c[0][2],c[0][0],c[0][1],c[0][2]

if c[1][1]==a2+b2 and c[1][2]==a2+b3 and\
c[2][1]==a3+b2 and c[2][2]==a3+b3:
    print('Yes')
else:
    print('No')

Failing test case input:
1 0 1
2 1 2
1 0 1

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
c = [list(map(int,input().split())) for i in range(3)]
a1,a2,a3,b1,b2,b3 = 0,c[1][0]-c[0][0],\
c[2][0]-c[0][0],c[0][0],c[0][1],c[0][2]

if c[1][1]==a2+b2 and c[1][2]==a2+b3 and\
c[2][1]==a3+b2 and c[2][2]==a3+b3:
    print('Yes')
else:
    print('No')
Problem: p03435
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
a=list(map(int,input().split()))
b=list(map(int,input().split()))
c=list(map(int,input().split()))
ans='Yes'
if a[1]-a[0]!=b[1]-b[0] or a[2]-a[1]!=b[2]-b[1]:
  ans='No'
elif b[0]-a[0]!=b[1]-a[1] or  b[2]-a[2]!=b[1]-a[1]:
  ans='No'
elif c[0]!=a[2]+b[0] or c[1]!=a[2]+b[1] or c[2]!=a[2]+b[2]:
  ans='No'
print(ans)

Failing test case input:
0 8 8
0 8 8
0 8 8

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
a=list(map(int,input().split()))
b=list(map(int,input().split()))
c=list(map(int,input().split()))
ans='No'
if a[1]-a[0]==b[1]-b[0]==c[1]-c[0] and a[2]-a[1]==b[2]-b[1]==c[2]-c[1]:
  if b[0]-a[0]==b[1]-a[1]==b[2]-a[2] and c[0]-b[0]==c[1]-b[1]==c[2]-b[2]:
    ans='Yes'
print(ans)

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
C=[list(map(int,input().split())) for i in range(3)]
for n in range(0,2):
  x=C[0][2]-C[0][n]
  y=C[1][2]-C[1][n]
  z=C[2][2]-C[2][n]
  if x==y and y==z :
    print('Yes')
    exit()
else:
  print('No')

Failing test case input:
0 8 8
0 8 8
0 0 8

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
C=[list(map(int,input().split())) for i in range(3)]
for n in range(0,2):
  x=C[0][2]-C[0][n]
  y=C[1][2]-C[1][n]
  z=C[2][2]-C[2][n]
  if x!=y or y!=z :
    print('No')
    exit()
else:
  print('Yes')

Problem: p03435
Buggy submission (Python (3.8.2), verdict: Wrong Answer):
lc = [[int(w) for w in input().split()] for i in range(3)]
cond = False

lb = lc[0]
a2 = lc[1][0]-lb[0]
a3 = lc[2][0]-lb[0]
la = [0, a2, a3]
for i in range(3):
    for j in range(3):
        if lc[i][j] != la[i]+lb[j]:
            flag = False
            break

print("Yes" if cond else "No")


Failing test case input:
0 8 8
0 8 8
0 8 8

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
lc = [[int(w) for w in input().split()] for i in range(3)]
cond = True

lb = lc[0]
a2 = lc[1][0]-lb[0]
a3 = lc[2][0]-lb[0]
la = [0, a2, a3]
for i in range(3):
    for j in range(3):
        if lc[i][j] != la[i]+lb[j]:
            cond = False
            break

print("Yes" if cond else "No")

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c = [[int(x) for x in input().split()] for _ in range(3)]
f = True
for i, j in zip(range(1,3), range(1,3)):
    if c[0][0]+c[i][j] != c[i][0]+c[0][j]:
        f = False
        break

print('Yes' if f else 'No')


Failing test case input:
0 8 8
0 8 8
0 0 8

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
c = [[int(x) for x in input().split()] for _ in range(3)]
f = True
from itertools import product
for i,j in product(range(1,3), range(1,3)):
        if c[0][0]+c[i][j] != c[i][0]+c[0][j]:
            f = False
            break

print('Yes' if f else 'No')
Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
l=[]
l.append(list(map(int,input().split())))
l.append(list(map(int,input().split())))
l.append(list(map(int,input().split())))
for i in range(2):
  if l[i][1]-l[i][0]!=l[i+1][1]-l[i+1][0] and l[i][2]-l[i][1]!=l[i+1][2]-l[i+1][1]:
    print('No')
    break
  if i==1:
    print('Yes')

Failing test case input:
1 0 1
4 1 2
1 0 1

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
l=[]
l.append(list(map(int,input().split())))
l.append(list(map(int,input().split())))
l.append(list(map(int,input().split())))
for i in range(2):
  if l[i][1]-l[i][0]!=l[i+1][1]-l[i+1][0] or l[i][2]-l[i][1]!=l[i+1][2]-l[i+1][1]:
    print('No')
    break
  if i==1:
    print('Yes')

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
C = [list(map(int, input().split())) for _ in range(3)]
a1 = 0
b1 = C[0][0] - a1
b2 = C[0][1] - a1
b3 = C[0][2] - a1
a2 = C[1][0] - b1
a3 = C[2][0] - b1
if C[0][0] == a1 + b1 :
    if C[0][0] == a1 + b1 :
        if C[0][0] == a1 + b1 :
            print('Yes')
else :
    print('No')

Failing test case input:
4 2 3
1 1 3
1 0 2

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
C = [list(map(int, input().split())) for _ in range(3)]
a1 = 0
b1 = C[0][0] - a1
b2 = C[0][1] - a1
b3 = C[0][2] - a1
a2 = C[1][0] - b1
a3 = C[2][0] - b1
if C[1][1] == a2 + b2 and C[1][2] == a2 + b3 and C[2][1] == a3 + b2 and C[2][2] == a3 + b3:
    print('Yes')
else :
    print('No')

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
def check(a,b):
    for i in range(3):
        diffc[i] = c[i][a]-c[i][b]
        diffr[i] = c[a][i]-c[b][i]
    if diffc[0] == diffc[1] == diffc[2] and diffr[0] == diffr[1] == diffr[2]:
        print("Yes")
        exit()

c = [[int(i) for i in input().split()] for i in range(3)]
diffr = [0]*3
diffc = [0]*3
check(0,1)
check(1,2)
print("No")

Failing test case input:
2 3 2
0 1 0
1 2 2

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
def check(a,b):
    for i in range(3):
        diffc[i] = c[i][a]-c[i][b]
        diffr[i] = c[a][i]-c[b][i]
    if diffc[0] != diffc[1] or diffc[1] != diffc[2] or diffr[0] != diffr[1] or diffr[1] != diffr[2]:
        print("No")
        exit()
        

c = [[int(i) for i in input().split()] for i in range(3)]
diffr = [0]*3
diffc = [0]*3
check(0,1)
check(1,2)
print("Yes")

Problem: p03435
Buggy submission (PyPy3 (7.3.0), verdict: Wrong Answer):
c=[list(map(int, input().split())) for i in range(3)]
if (c[0][0] - c[1][0] == c[0][1] - c[1][1] == c[0][2] - c[1][2]) and \
   (c[0][1] - c[1][2] == c[1][1] - c[2][1] == c[1][2] - c[2][2]):
    print('Yes')
else:
    print('No')

Failing test case input:
1 0 1
2 1 2
1 0 1

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
c=[list(map(int, input().split())) for i in range(3)]
if (c[0][0] - c[1][0] == c[0][1] - c[1][1] == c[0][2] - c[1][2]) and \
   (c[1][0] - c[2][0] == c[1][1] - c[2][1] == c[1][2] - c[2][2]):
    print('Yes')
else:
    print('No')
Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c = [list(map(int,input().split())) for _ in range(3)]
b = c[0]
a = [0]
for i in range(1,3):
    a.append(c[i][i]-b[i])
for i in range(3):
    for j in range(3):
        if c[i][j] != a[i] + b[j]:
            print('NO')
            exit()
print('YES')

Failing test case input:
4 1 -2
0 1 3
1 1 1

Expected output:
No


Actual output:
NO


Fixed submission (verdict: Accepted):
c = [list(map(int,input().split())) for _ in range(3)]
b = c[0]
a = [0]
for i in range(1,3):
    a.append(c[i][i]-b[i])
for i in range(3):
    for j in range(3):
        if c[i][j] != a[i] + b[j]:
            print('No')
            exit()
print('Yes')

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
lst = []
for i in range(3):
	a = list(map(int,input().split()))
	lst.append(a)

F = False

for i in range(100):
	b1 = lst[0][0] - i
	b2 = lst[0][1] - i
	b3 = lst[0][0] - i
	if lst[1][0] - b1 == lst[1][1] - b2 and +\
	lst[1][1] - b2 == lst[1][2] - b3 and +\
	lst[2][0] - b1 == lst[2][1] - b2 and +\
	lst[2][1] - b2 == lst[2][2] - b3:
		F = True

if F == False:
  print("No")
else:
  print("Yes")

Failing test case input:
0 8 8
0 8 8
0 8 8

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):
lst = []
for i in range(3):
	a = list(map(int,input().split()))
	lst.append(a)

F = False

for i in range(100):
	b1 = lst[0][0] - i
	b2 = lst[0][1] - i
	b3 = lst[0][2] - i
	if lst[1][0] - b1 == lst[1][1] - b2 and +\
	lst[1][1] - b2 == lst[1][2] - b3 and +\
	lst[2][0] - b1 == lst[2][1] - b2 and +\
	lst[2][1] - b2 == lst[2][2] - b3:
		F = True

if F == False:
  print("No")
else:
  print("Yes")

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c = [list(map(int, input().split())) for i in range(3)]
ans = False
flag = False

for i in range(3):
    for j in range(3):
        if c[i][j] < min(c[i]) + min([c[0][j], c[1][j], c[2][j]]):
            flag = True
            continue
        if i == 2 and j == 2:
            ans = True
    if flag:
        break

if ans:
    print('Yes')
else:
    print('No')


Failing test case input:
2 6 2
0 1 0
1 2 2

Expected output:
No


Actual output:
Yes


Fixed submission (verdict: Accepted):
c = [list(map(int, input().split())) for i in range(3)]
ans = False

for i in range(101):
    b = [c[0][0]-i, c[0][1]-i, c[0][2]-i]
    a = [i, c[1][0]-b[0], c[2][0]-b[0]]
    flag = False
    for j in range(3):
        for k in range(3):
            if c[j][k] != a[j] + b[k]:
                flag = True
                break
            if j == 2 and k == 2:
                ans = True
        if flag:
            break

if ans:
    print('Yes')
else:
    print('No')
Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):


c = []
for i in range(3):
    c.append(list(map(int, input().split())))
diff1 = []
for i in range(2):
    diff1.append([s - t for s in c[i+1][:] for t in c[i][:]])

diff2 = []
for i in range(2):
    diff2.append([s - t for s in c[:][i+1] for t in c[:][i]])

if diff1[0] == diff1[1] and diff2[0] == diff2[1]:
    print('Yes')
else:
    print('No')

Failing test case input:
1 0 1
2 1 2
1 0 1

Expected output:
Yes

Actual output:
No


Fixed submission (verdict: Accepted):


c = []
for i in range(3):
    c.append(list(map(int, input().split())))
diff1 = []
for i in range(3):
    diff1.append([c[i][1] - c[i][0], c[i][1] - c[i][2]])

diff2 = []
for i in range(3):
    diff2.append([c[1][i] - c[0][i], c[1][i] - c[2][i]])
if diff1[0] == diff1[1] and diff1[1] == diff1[2] and \
   diff2[0] == diff2[1] and diff2[1] == diff2[2]:
    print('Yes')
else:
    print('No')

Problem: p03435
Buggy submission (Python (3.4.3), verdict: Wrong Answer):
c = []
for _ in range(3) :
    c += [list(map(int, input().split()))]
a1 = c[1][0]-c[0][0]
a2 = c[2][0]-c[0][0]
c1 = [c[0][i] + a1 for i in range(3)]
c2 = [c[0][i] + a2 for i in range(3)]
if c[1] == c1 and c[2] == c2 :
    print("yes")
else :
    print("no")

Failing test case input:
1 0 1
0 1 5
0 0 1

Expected output:
No


Actual output:
no


Fixed submission (verdict: Accepted):
c = []
for _ in range(3) :
    c += [list(map(int, input().split()))]
a1 = c[1][0]-c[0][0]
a2 = c[2][0]-c[0][0]
c1 = [c[0][i] + a1 for i in range(3)]
c2 = [c[0][i] + a2 for i in range(3)]
if c[1] == c1 and c[2] == c2 :
    print("Yes")
else :
    print("No")
Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
dataset = []
while True:
    x, y = map(int, input().split())
    if not(x >= 0 and x <= 10000) and (y >= 0 and y <= 10000):
        break
    elif (x is not 0) and (y is not 0): 
        listed = []
        listed.append(x)
        listed.append(y)
        dataset.append(listed)
        if len(dataset) > 3000:
            break
    else:
        break

for i in dataset:
    min = i[0]
    max = i[0]
    if i[0] > i[1]:
        min = i[1]
        max = i[0]
    elif i[0] < i[1]:
        min = i[0]
        max = i[1]
    print("{0} {1}".format(str(min), str(max)))

Failing test case input:
3 1
-1 1
0 1
0 0

Expected output:
1 3
-1 1
0 1


Actual output:
1 3


Fixed submission (verdict: Accepted):
dataset = []
while True:
    x, y = map(int, input().split())
    if (x < 0 and x > 10000) and (y < 0 and y > 10000):
        break
    elif (x is 0) and (y is 0): 
        break

    listed = []
    listed.append(x)
    listed.append(y)
    dataset.append(listed)
    if len(dataset) >= 3000:
        break

for i in dataset:
    if i[0] > i[1]:
        print("{0} {1}".format(str(i[1]), str(i[0])))
    elif i[0] < i[1]:
        print("{0} {1}".format(str(i[0]), str(i[1])))
    else:
        print("{0} {1}".format(str(i[0]), str(i[1])))

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    a,b = map(int,input().split())
    if a ==0 and b ==0:
        break
    else:
        a,b =b,a
        print(b,a)


Failing test case input:
3 2
2 6
5 6
0 0

Expected output:
2 3
2 6
5 6


Actual output:
3 2
2 6
5 6


Fixed submission (verdict: Accepted):
while True:
    a,b = map(int,input().split())
    if a ==0 and b ==0:
        break
    else:
        if a<=b:
            print(a,b)
        else:
            a,b =b,a
            print(a,b)

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
while True :
    x, y = map(int, input().split())

    if x == 0 & y == 0 :
        break
    elif x > y :
        z = x
        x = y
        y = z
        print(str(x) + " " + str(y))
    else :
        print(str(x) + " " + str(y))

Failing test case input:
3 1
-1 2
0 1
0 0

Expected output:
1 3
-1 2
0 1


Actual output:
1 3
-1 2


Fixed submission (verdict: Accepted):
while True :
    x, y = map(int, input().split())

    if (x == 0) & (y == 0) :
        break
    elif x > y :
        print(y, x)
    else :
        print(str(x) + " " + str(y))

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
xy_data=[]
while True:
    xy=list(map(int,input().split()))
    xy.sort()
    print(xy)
    if xy[0]==xy[1]==0:
        break
    else:
        xy_data.append(xy)
for xy in xy_data:
    print(*xy)

Failing test case input:
4 3
1 5
5 6
0 0

Expected output:
3 4
1 5
5 6


Actual output:
[3, 4]
[1, 5]
[5, 6]
[0, 0]
3 4
1 5
5 6


Fixed submission (verdict: Accepted):
xy_data=[]
while True:
    xy=list(map(int,input().split()))
    xy.sort()
    if xy[0]==xy[1]==0:
        break
    else:
        xy_data.append(xy)
for xy in xy_data:
    print(*xy)
Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    c = input().split()
    x, y = int(c[0]), int(c[1])
    if x == y == 0:
        break
    print("%d %d" % (y, x))



Failing test case input:
3 2
-1 4
0 1
0 0

Expected output:
2 3
-1 4
0 1


Actual output:
2 3
4 -1
1 0


Fixed submission (verdict: Accepted):
while True:
    c = input().split()
    x, y = int(c[0]), int(c[1])
    if x == y == 0:
        break
    if y < x:
        x, y = y, x
    print("%d %d" % (x, y))

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    x, y = map(int, input().split())
    if x == y == 0: break

    print(y, x)


Failing test case input:
3 0
-1 2
0 1
0 0

Expected output:
0 3
-1 2
0 1


Actual output:
0 3
2 -1
1 0


Fixed submission (verdict: Accepted):
while True:
    x, y = map(int, input().split())
    if x == y == 0: break

    print(*sorted([x, y]))

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):

newArray = []

x, y = input().split()

while x != "0" and y != "0":
    if x < y or x == y:
        pass
    else:
        w = x
        x = y
        y = w
    newArray.append([x, y])
    x, y = input().split()

for i in range(len(newArray)):
    print(newArray[i][0] + " " + newArray[i][1])

Failing test case input:
1 0
-1 3
0 0
2 4

Expected output:
0 1
-1 3


Actual output:

Fixed submission (verdict: Accepted):
newArray = []

x, y = input().split()

while x + y != "00":
    x = int(x)
    y = int(y)
    if x < y or x == y:
        newArray.append([str(x), str(y)])
    else:
        newArray.append([str(y), str(x)])
    x, y = input().split()

for i in range(len(newArray)):
    print(newArray[i][0] + " " + newArray[i][1])

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
datalist = []
Flag = True
for i in range(3000):
    if Flag:
        x, y = map(int, input().split())
        if x == 0:
            Flag = False
        else:
            datalist.append((x, y))

for (i,j) in datalist:
    if i < j :
        print("{} {}".format(i, j))
    else:
        print("{} {}".format(j, i))


Failing test case input:
3 0
0 2
9 3
0 0

Expected output:
0 3
0 2
3 9


Actual output:
0 3


Fixed submission (verdict: Accepted):
datalist = []
Flag = True
for i in range(3000):
    if Flag:
        x, y = map(int, input().split())
        if x == 0 and y == 0:
            Flag = False
        else:
            datalist.append((x, y))

for (i,j) in datalist:
    if i < j :
        print("{} {}".format(i, j))
    else:
        print("{} {}".format(j, i))

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    x, y = map(int, input().split())
    if x == y == 0: break

    print(y, x, sep = " ")


Failing test case input:
1 0
0 2
0 1
0 0

Expected output:
0 1
0 2
0 1


Actual output:
0 1
2 0
1 0


Fixed submission (verdict: Accepted):
while True:
    x, y = map(int, input().split())
    if x == y == 0: break

    print(*sorted([x, y]))
Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
for i in range(3000):
  x,y=map(int,input().split())
  if x == 0 and y == 0:
     break
  print('{0} {1}'.format(y,x))

Failing test case input:
3 0
0 2
9 5
0 0

Expected output:
0 3
0 2
5 9


Actual output:
0 3
2 0
5 9


Fixed submission (verdict: Accepted):
for i in range(3000):
  x,y=map(int,input().split())
  if x == 0 and y == 0:
    break
  print('{0} {1}'.format(min(x,y),max(x,y)))

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
x=1
y=1
while x!=0 and y!=0 :
	x,y=map(int, input().split(" "))
	if y<x :
		k=x
		x=y
		y=k
	print(x,"",+y)

Failing test case input:
3 0
0 2
27 3
0 0

Expected output:
0 3
0 2
3 27


Actual output:
0  3


Fixed submission (verdict: Accepted):
x=1
y=1
while True :
	x,y=map(int, input().split(" "))
	if x==0 and y==0 :
		break
	if y<x :
		k=x
		x=y
		y=k
	print(x,y)

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
I = input().split()
x = int(I[0])
y = int(I[1])
while x != 0 and y != 0:
    if x < y:
        print(str(x) + ' ' + str(y))
    if x > y:
        print(str(y) + ' ' + str(x))
    if x == y:
        print(str(x) + ' ' + str(y))
    I = input().split()
    x = int(I[0])
    y = int(I[1])

Failing test case input:
0 1
2 1
9 3
0 0

Expected output:
0 1
1 2
3 9


Actual output:

Fixed submission (verdict: Accepted):
I = input().split()
x = int(I[0])
y = int(I[1])
while x != 0 or y != 0:
    if x < y:
        print(str(x) + ' ' + str(y))
    if x > y:
        print(str(y) + ' ' + str(x))
    if x == y:
        print(str(x) + ' ' + str(y))
    I = input().split()
    x = int(I[0])
    y = int(I[1])

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
x,y = input().split()
x = int(x)
y = int(y)
i = 0
if x == 0 and y == 0:
    if x > y:
        i = x
        x = y
        y = i

    fmt = "{a} {b}"
    s = fmt.format(a = x,b = y)
    print(s)

Failing test case input:
1 0
0 2
0 1
0 0

Expected output:
0 1
0 2
0 1


Actual output:

Fixed submission (verdict: Accepted):

i = 0
j = 0
lis = []
while True:
    x,y = input().split()
    x = int(x)
    y = int(y)
    if x > y:
        i = x
        x = y
        y = i

    if x == 0 and y == 0:
        break
    fmt = "{a} {b}"
    s = fmt.format(a = x,b = y)
    lis.append(s)
    j += 1

for i in range(j):
    print(lis[i])

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
while True:
 a,b=map(int,input().split())
 if not(a) and not(b):break
 print(b,a)

Failing test case input:
3 3
0 5
5 6
0 0

Expected output:
3 3
0 5
5 6


Actual output:
3 3
5 0
6 5


Fixed submission (verdict: Accepted):
while True:
 a,b=map(int,input().split())
 if not(a) and not(b):break
 if a>b:a,b=b,a
 print(a,b)
Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    x, y = map(int, input().split(" "))
    if x == 0 and y == 0:
        break
    elif x <  y: 
     print(x, y)
    elif x > y: 
     print(y, x)

Failing test case input:
7 2
1 1
1 6
0 0

Expected output:
2 7
1 1
1 6


Actual output:
2 7
1 6


Fixed submission (verdict: Accepted):

while True:
    x, y = map(int, input().split(" "))
    if x == 0 and y == 0:
     break
    elif x <=  y:
     print(x, y)
    elif x >= y:
     print(y, x)

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
import sys

while 1:
  str = sys.stdin.readline().strip()
  if str=="0 0":
    break
  print(sorted(str.split(" "), key=int))

Failing test case input:
1 0
0 3
0 0
1 0

Expected output:
0 1
0 3


Actual output:
['0', '1']
['0', '3']


Fixed submission (verdict: Accepted):
import sys

while 1:
  str = sys.stdin.readline().strip()
  if str=="0 0":
    break
  print(" ".join(sorted(str.split(" "), key=int)))

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    (x, y) = [int(i) for i in input().split()]
    print(x, y)
    if x > y:
        (x, y) == (y, x)
    if x == 0 and y == 0:
        break
    print(x, y)

Failing test case input:
3 2
2 5
5 6
0 0

Expected output:
2 3
2 5
5 6


Actual output:
3 2
3 2
2 5
2 5
5 6
5 6
0 0


Fixed submission (verdict: Accepted):
while True:
    (x, y) = [int(i) for i in input().split()]
    
    if x == 0 and y == 0:
        break
    if x >= y:
        print(y, x)
    else:
        print(x, y)

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    x, y = map(int, input().split())
    if x == 0 and y == 0:
        break
    else:
        a = [x, y]
        a.sort()
        print(a)

Failing test case input:
0 2
3 6
5 6
0 0

Expected output:
0 2
3 6
5 6


Actual output:
[0, 2]
[3, 6]
[5, 6]


Fixed submission (verdict: Accepted):
while True:
    x, y = map(int, input().split())
    if x == 0 and y == 0:
        break
    else:
        a = [x, y]
        a.sort()
        print(a[0], a[1])

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    x, y = map(int, input().split())
    if x == y == 0:
        break
    else:
        if x < y:
            print("{} {}".format(x, y))
        elif x > y:
            print("{} {}".format(y, x))


Failing test case input:
7 0
1 1
1 6
0 0

Expected output:
0 7
1 1
1 6


Actual output:
0 7
1 6


Fixed submission (verdict: Accepted):
while True:
    x, y = map(int, input().split())
    if x == y == 0:
        break
    else:
        if x > y:
            print(y, x)
        else:
            print(x, y)

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
while True:
    a, b = map(int, input().split())
    if a == 0 and b == 0:
        break
    print("{} {}".format(b, a))

Failing test case input:
1 1
1 3
9 3
0 0

Expected output:
1 1
1 3
3 9


Actual output:
1 1
3 1
3 9


Fixed submission (verdict: Accepted):
while True:
    a = list(map(int, input().split()))
    if a[0] == 0 and a[1] == 0:
        break

    a.sort()
    print("{} {}".format(a[0], a[1]))
Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
import sys
for i in sys.stdin:
    print(i)
    a, b = sorted(map(int, i.split()))
    if a != 0 or b != 0:
        print(a, b)
    else:
        break

Failing test case input:
0 2
3 6
5 6
0 0

Expected output:
0 2
3 6
5 6


Actual output:
0 2

0 2
3 6

3 6
5 6

5 6
0 0



Fixed submission (verdict: Accepted):
import sys
for i in sys.stdin:
    a, b = sorted(map(int, i.split()))
    if a != 0 or b != 0:
        print(a, b)
    else:
        break

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
while(True):
    i,j=input().split()
    
    if i != '0' and j != '0':
        if int(i) <= int(j):
            print('{} {}'.format(i,j))
        else:
            print('{} {}'.format(j,i))
    else:
        break


Failing test case input:
0 1
2 1
11 3
0 0

Expected output:
0 1
1 2
3 11


Actual output:

Fixed submission (verdict: Accepted):
while(True):
    i,j=input().split()
    
    if i != '0' or j != '0':
        if int(i) <= int(j):
            print('{} {}'.format(i,j))
        else:
            print('{} {}'.format(j,i))
    else:
        break

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
a,b=map(int,input().split())
while a!=0 and b!=0:
    if a<b:
        print(a,b)
    else:
        print(b,a)
    a,b=map(int,input().split())



Failing test case input:
3 0
-1 4
0 1
0 0

Expected output:
0 3
-1 4
0 1


Actual output:

Fixed submission (verdict: Accepted):
while 1:
    a,b=map(int,input().split())
    if a==b==0:
        break
    if a<b:
        print(a,b)
    else:
        print(b,a)

Problem: p02397
Buggy submission (Python3, verdict: Wrong Answer):
import sys

while 1:
    x = sys.stdin.readline().strip()
    x_list = x.split(" ")
    
    if x_list[0] == "0" and x_list[1] == "0" :
        break
    
    x_list.sort()
    print(x_list[0],x_list[1])

Failing test case input:
0 1
2 1
11 3
0 0

Expected output:
0 1
1 2
3 11


Actual output:
0 1
1 2
11 3


Fixed submission (verdict: Accepted):
import sys

while 1:
    x = sys.stdin.readline().strip()
    x_list = list(map(int,x.split(" ")))
    
    if x_list[0] == 0 and x_list[1] == 0 :
        break
    
    x_list.sort()
    print(x_list[0],x_list[1])