qyliang/CodeNanoFix huggingface dataset:
Buggy code:
W,H,x,y,r = (int(i) for i in input().split())
if W-x+r >= 0 and H-y+r >= 0:
    print("Yes")
else:
    print("No")

Fixed code:
W, H, x, y, r = (int(x) for x in input().split())
if(x - r >= 0 and x + r <= W and y - r >= 0 and y + r <= H):
    print("Yes")
else:
    print("No")
Buggy code:
w,h,x,y,r = map(int,input().split())
if x >= r and x =< w-r and y >= r and y =< h-r:
    print("Yes")
else:
    print("No")



Fixed code:
w,h,x,y,r = map(int,input().split())
if x - r >= 0 and x + r <= w and y - r >= 0 and y + r <= h:
    print("Yes")
else:
    print("No")
Buggy code:
Indata = [int(i) for i in input().split()]
W,H,x,y,r = [int(i) for i in Indata]
x_right = x+r
x_left = x-r
y_on = y+r
y_under = y-r

if x_right>W || x_left<0 || y_on>H || y_under<0:
    print("No")
else:
    print("Yes")


Fixed code:
Indata = [int(i) for i in input().split()]
W,H,x,y,r = [int(i) for i in Indata]
x_right = x+r
x_left = x-r
y_on = y+r
y_under = y-r

if x_right>W or x_left<0 or y_on>H or y_under<0:
    print("No")
else:
    print("Yes")
Buggy code:
W,H,x,y,r=map(int,input().split())
if not x+r>W or r>x or r>y or y+r>H:
 print("Yes")
else :
 print("No")

Fixed code:
W,H,x,y,r=map(int,input().split())
if not (x+r>W or r>x or r>y or y+r>H):print("Yes")
else:print("No")
Buggy code:
W, H, r, x ,y = list(map(int,input().split()))
if 0 <= x - r <= x + r = W and 0 <= y - r <= y + r = H:
 print('Yes')
else:
 print('No')

Fixed code:
W,H,x,y,r = map(int,input().split())

if x+r <= W and x-r >= 0 and y+r <= H and y-r >= 0 :
    print("Yes")
else:
    print("No")
Buggy code:
W,H,x,y,r = map(int, input().split())
if W < (x+r) and H < (y + r) and 0 > (x+r) and 0 > (y+r) :
  print("No")
else :
  print("Yes")


Fixed code:
W, H, x, y , r = map(int, input().split())
if x - r >= 0 and y - r >=0 and y + r <= H and x + r <= W:
    print("Yes")
else:
    print("No")
Buggy code:
# Circle in a Rectangle

a = [int(i) for i in input().rstrip().split()]
rectangle = [a[0], a[1]]
circleCenter = [a[2], a[3]]
circleRadius = a[4]

if a[2] - a[4] >= 0 and a[2] + a[4] <= a[0]:
    if a[3] - [4] >= 0 and a[3] + a[4] <= a[1]:
        print('Yes')
    else:
        print('No')
else:
    print('No')



Fixed code:
# Circle in a Rectangle

a = [int(i) for i in input().rstrip().split()]
rectangle = [a[0], a[1]]
circleCenter = [a[2], a[3]]
circleRadius = a[4]

if a[2] - a[4] >= 0 and a[2] + a[4] <= a[0]:
    if a[3] - a[4] >= 0 and a[3] + a[4] <= a[1]:
        print('Yes')
    else:
        print('No')
else:
    print('No')
Buggy code:
input = input()
W,H,x,y,r = map(int ,input.split())
if x - r < 0 or x + r > W or y - r < 0 or y + r > H:
    print("No")
if x - r >= 0 and x + r <= W and y - r >= 0 and x + r <= H:
    print("Yes")


Fixed code:
W,H,x,y,r=map(int,input().split())

if x-r < 0 or x+r > W or y-r < 0 or y+r > H:
    print('No')
else:
    print('Yes')
Buggy code:
W,H,x,y,r = map(int,input().split())

if x-r < 0 or x+r > W:
 print("No")
elif x-r > 0 or x+r < W:
 print("Yes")
elif y-r < 0 or y+r > W:
 print("No")
else:
 print("Yes")

Fixed code:
W,H,x,y,r=map(int,input().split())
if x+r>W or y+r>H or x-r<0 or y-r<0:
    print("No")
else:
    print("Yes")
Buggy code:
import sys

s = sys.stdin

cnt = 1
for i in s:
    if int(i)== 0:
        break
    print("Case {0}: {1}".format(cnt,i))
    cnt += 1

Fixed code:
import sys

s = sys.stdin

cnt = 1
for i in s:
    if int(i)== 0:
        break
    print("Case {0}: {1}".format(cnt,i),end="")
    cnt += 1
Buggy code:
counter = 0
while 1:
  i = int(input())
  if i == 0:
    break
  counter += 1
  print("Case {0}: {1}".format(counter, i)

Fixed code:
counter = 0
while 1:
  i = int(input())
  if i == 0:
    break
  counter += 1
  print("Case {0}: {1}".format(counter, i))
Buggy code:
counter=0

while True:
    counter+=1
    x=int(input())
    if x==0:
        break
    print("Case "+counter+": "+x)


Fixed code:
counter=0

while True:
    counter+=1
    x=int(input())
    if x==0:
        break
    print("Case "+str(counter)+": "+str(x))
Buggy code:
import sys

count = 0
num = []
while True:
	x = int(input())
	if x == 0 :
		break
	num.append(x)

for i in range(len(num)):
	print ("Case ", i+1, ": ",num[i])

Fixed code:
import sys

count = 0
num = []
while True:
	x = int(input())
	if x == 0 :
		break
	num.append(x)

for i in range(len(num)):
	print ("Case " + str((i+1)) + ":",num[i] )
Buggy code:
import sys

a = []

for line in sys.stdin:
    a.append(int(line))
print(a)

cnt = 0
for i in a:
    cnt += 1
    if i == 0:
        break
    print("Case " + str(cnt) + ": " + str(i))
    


Fixed code:
import sys

a = []

for line in sys.stdin:
    a.append(int(line))

cnt = 0
for i in a:
    cnt += 1
    if i == 0:
        break
    print("Case " + str(cnt) + ": " + str(i))
Buggy code:

num = 1

While True:
    x = int(input())
    if x == 0: break
    print ("Case {0}: {1}".format(num,x))
    num += 1


Fixed code:

num = 1

while True:
    x = int(input())
    if x == 0: break
    print ("Case {0}: {1}".format(num,x))
    num += 1
Buggy code:
import sys
a = sys.stdin
i = 1
for line in a:
    if(int(line) == 0):
        break
    print('Case{0}:{1}'.format(i,line),end="")
    i += 1

Fixed code:
import sys
a = sys.stdin
i = 1
for line in a:
    if(int(line) == 0):
        break
    print('Case {0}: {1}'.format(i,line),end="")
    i += 1
Buggy code:
li=[]
a=1
while(a!=0):
    a=int(input())
    li.append(a)
for i in range(1,len(li)+1):
    if li[i-1]!=0:
        print("case　{0}: {1}".format(i,li[i-1]))
    else:
        break


Fixed code:
li=[]
a=1
while(a!=0):
    a=int(input())
    li.append(a)
for i in range(1,len(li)+1):
    if li[i-1]!=0:
        print("Case {0}: {1}".format(i,li[i-1]))
    else:
        break
Buggy code:
i=1
while(True):
    x = int(input())
    if not x:
        break
    print('Case {0}: {1}'.format(i+1, x))
    i+=1

Fixed code:
i = 1
while True:
    x = int(input())
    if x == 0: break
    print("Case {}: {}".format(i, x))
    i += 1
Buggy code:
count = 1
while True:
x = input().strip()
if x == '0':
     break
print('Case %s: %s' % (count, x))
count = count + 1

Fixed code:
import sys
count = 1
while True:
    x = input().strip()
    if x == '0':
         break
    print('Case %s: %s' % (count, x))
    count = count + 1
Buggy code:
b = []
i = 1
while 1:
    x = int(input())
    b.append(x)
    print(x)
    if x == 0:
        break

for x in b:
    if x == 0:
        break
    print("Case ", (i), ': ', (x), sep='')
    i +=1

Fixed code:
b = []
i = 1
while 1:
    x = int(input())
    b.append(x)
    if x == 0:
        break

for x in b:
    if x == 0:
        break
    print("Case ", (i), ': ', (x), sep='')
    i += 1
Buggy code:
c = 1
while True:
    x = int(input())
    if x == 0: break
    c += 1
    print("Case {}: {}".format(c, x))


Fixed code:
c = 0
while True:
	x = int(input()); c += 1
	if x == 0:       break
	print("Case {}: {}".format(c, x))
Buggy code:
c = 1                                                                       
a = []
while True:
    x = int(input())
    a = a + [x]
    if x == 0:
        break;

for i in a:
    print('Case {0}: {1}'.format(c,i))
    c += 1

Fixed code:
c = 1                                                                       
a = []
while True:
    x = int(input())
    if x == 0:
        break;
    else:
        a = a + [x]

for i in a:
    print('Case {0}: {1}'.format(c,i))
    c += 1
Buggy code:
# coding: utf-8
import sys

line = sys.stdin

count = 1
for x in line :
	if int(x) == 0 :
		break
	print('Case {0}: {1}'.format(count, x))
	count += 1

Fixed code:
# coding: utf-8
import sys

line = sys.stdin

count = 1
for x in line :
	if int(x) == 0 :
		break
	print('Case {0}: {1}'.format(count, x.strip()))
	count += 1
Buggy code:
x    = input()
case = 1

while x != '0' :
    print('case {}: {}'.format(case, x))
    x = input()
    case += 1

Fixed code:
x    = input()
case = 1

while x != '0' :
    print('Case {}: {}'.format(case, x))
    x = input()
    case += 1
Buggy code:
n = 1
x = int(input())
while x != 0 :
    print("Case  {} : {}".format(n,x)
    n = n+1
    x = int(input())


Fixed code:
n = 1
x = int(input())
while x != 0 :
    print("Case {}: {}".format(n,x))
    n = n+1
    x = int(input())
Buggy code:
#!/usr/bin/python3
# -*- coding: utf-8 -*-

import sys

num = 0
while True:
    s = sys.stdin.readline().strip()
    if s == '0':
        break
    num += 1
    print('Case: ', num, ' ', s, sep='')



Fixed code:
#!/usr/bin/python3
# -*- coding: utf-8 -*-

import sys

num = 0
while True:
    s = sys.stdin.readline().strip()
    if s == '0':
        break
    num += 1
    print('Case ', num, ': ', s, sep='')
Buggy code:
i = 1
while True:
     x = int(input())
     if x == 0 break:
     print('Case {}: {}'.format(i, x))
     i += 1

Fixed code:
count=1
while True:
    x=int(input())
    if x == 0:
        break
    print("Case {}: {}".format(count, x))
    count+=1
Buggy code:
#!usr/bin/env python3

def main():
    count = 1
    while True:
        x = int(input())
        print('Case ' + str(count) + ': ' + str(x))
        count += 1
        if x == 0:
            break


if __name__ == '__main__':
    main()


# NOTE AOJ question URL (Repetitive Processing - Print Test Cases):
# http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=ITP1_3_B

Fixed code:
#!usr/bin/env python3

def main():
    count = 1
    while True:
        x = int(input())
        if x == 0:
            break
        print('Case %d: %d' % (count, x))
        count += 1


if __name__ == '__main__':
    main()


# NOTE AOJ question URL (Repetitive Processing - Print Test Cases):
# http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=ITP1_3_B
Buggy code:
for i in range(10000)
  line = int(input())
  if line == 0:
    break
  print('Case {}: {}'.format(i+1, line))

Fixed code:
for i in range(10000):
  line = int(input())
  if line == 0:
    break
  print('Case {}: {}'.format(i+1, line))
Buggy code:
array = []
x = input()
while x != 0:
    array.append(x)
    x = input()
for i, x in enumerate(array):
    print("Case %d: %d" % (i + 1, x))


Fixed code:
array = []
x = input()
while x != "0":
    array.append(x)
    x = input()
for i, x in enumerate(array):
    print("Case %d: %s" % (i + 1, x))
Buggy code:
n = 1
while True:
    x = int(input())
    if x == 0:
        break
    print('Case{}: {}'.format(n, x))
    n += 1

Fixed code:
n = 1
while True:
    x = int(input())
    if x == 0:
        break
    print("Case {}: {}".format(n, x))
    n += 1
Buggy code:
i = 1

x=int(input())
if x==0:
 break
print("Case {0}: {1}".format(i,x))
i+=1

Fixed code:
i = 1

while True:

 x=int(input())
 if x==0:
  break
 print("Case {0}: {1}".format(i,x))
 i+=1
Buggy code:
count = 0
while true:
    count += 1
    a = int(input())
    if a == 0:
        break
    print("Case {}: {}".format(count, a))


Fixed code:
count = 0
while True:
    count += 1
    a = int(input())
    if a == 0:
        break
    print("Case {}: {}".format(count, a))
Buggy code:
def main():
	i = 1
	while True:
		num = int(input())
		print('Case {0}: {1}'.format(i, num))
		i += 1

		if num == 0:
			break


if __name__=="__main__":
	main()
	

Fixed code:
def main():
	i = 1
	while True:
		num = int(input())
		if num == 0:
			break
		else:
			print('Case {0}: {1}'.format(i, num))
			i += 1


if __name__=="__main__":
	main()
Buggy code:
a = 1
while True:
  i = int(input())
  if (i == 0):
    break
  print("Case %d:%d" % (a, i))
  a += 1
       

Fixed code:
a = 1 
while True:
  i = int(input())
  if (i == 0):
    break
  print("Case %d: %d" % (a, i))
  a += 1
Buggy code:
# import
import sys

# case??????
i = 1

# input???????????????
for s in sys.stdin:
    # 0?????´??? ????????????
    if int(s) == 0:
        break

    # ????????????
    print("Case ",i,": ",int(s))
    # case???????????????????????????
    i += 1

Fixed code:
# import
import sys

# case??????
i = 1

# input???????????????
for s in sys.stdin:
    # 0?????´??? ????????????
    if int(s) == 0:
        break

    # ????????????
    print("Case ",i,": ",int(s),sep="")
    # case???????????????????????????
    i += 1
Buggy code:
c = 1

while True :
    x = int(input())
    if (x == 0) :
        break;
    print('Case {0} : {1}'.format(c,x))
    c += 1

Fixed code:
i = 0
while True:
    x = int(input()); i += 1
    if x == 0: break
    print("Case {}: {}".format(i, x))
Buggy code:
n = 1
while True:
    x = int(input())
    if x == 0:
        break
    print("Case {}:{}".format(n, x))
    n += 1



Fixed code:
n = 1
while True:
    x = int(input())
    if x == 0:
        break
    print("Case {}: {}".format(n, x))
    n += 1
Buggy code:
x=int(input())
i=1;
while True:
   if x==0:
     break
   print(f"Case {i}: {x}")


Fixed code:
i=1
while True:
    x=int(input())
    if x==0:
        break
    print(f"Case {i}: {x}")
    i+=1
Buggy code:
a = []
while True:
    b = input()
    b = int(b)
    if b == 0:
        break
    else:
        a.append(b)
for i in range(len(a)):
    print("Case "+str(i)+": "+str(a[i]))


Fixed code:
a = []
while True:
    b = input()
    b = int(b)
    if b == 0:
        break
    else:
        a.append(b)
for i in range(len(a)):
    c = i+1
    print("Case "+str(c)+": "+str(a[i]))
Buggy code:
i=1
while True:
 s=int(input)
 if s==0:break
 print(f'Case {i}: {s}')

Fixed code:
i=1
while True:
 s=int(input())
 if s==0:break
 print(f'Case {i}: {s}')
 i+=1
Buggy code:
i=1
while True:
 n=input()
 if int(n)==0:break
 print(f'Case {i}: {n}')

Fixed code:
i=1
while True:
 n=input()
 if int(n)==0:break
 print(f'Case {i}: {n}')
 i+=1
Buggy code:
a=[]
while True:
 n=input()
 if n==0:
  break
 a.append(n)
for i in range(len(a)):
 print(f'Case {i+1}: {a[i]}')

Fixed code:
a=[]
b=a.append
while True:
 n=input()
 if int(n)==0:break
 b(n)
for i in range(len(a)):print(f'Case {i+1}: {a[i]}')
Buggy code:
i=1
while 1:
 a=input()
 if a==0:break
 print(f'Case {i}: {a}')
 i+=1

Fixed code:
i=1
while 1:
 a=input()
 if int(a)==0:break
 print(f'Case {i}: {a}')
 i+=1
Buggy code:
for i,a in enumerate(iter(input,'0')):
 print(f'Case {i}: {a}')


Fixed code:
for i,a in enumerate(iter(input,'0'),1):print(f'Case {i}: {a}')
Buggy code:
import sys
i=1
for a in sys.stdin:
 a=a.strip()
 if a==0:break
 print(f'Case {i}: {a}')
 i+=1

Fixed code:
import sys
i=1
for a in sys.stdin:
 a=a.strip()
 if'0'==a:break
 print(f'Case {i}: {a}')
 i+=1
Buggy code:
import sys
i=1
for a in sys.stdin.readlines():
 if'0'==a:break
 print(f'Case {i}: {a}');i+=1


Fixed code:
import sys
i=1
for a in sys.stdin:
 a=a.strip()
 if a=='0':break
 print(f'Case {i}: {a}');i+=1
Buggy code:
for i in range(10000):
    x = input()
    x = int(x)
    
    if x == 0:
        break
    else:
        print("Case "+str(i+1) + ":" + str(x))



Fixed code:
for i in range(10000):
    x = input()
    x = int(x)
    
    if x == 0:
        break
    else:
        print("Case "+ str(i+1) + ": " + str(x))
Buggy code:
#! python3
# print_test_cases.py

for i in range(10000):
    x = int(input())
    if x == 0:
        break
    print('Case ' + str(i) + ': ' + str(x))


Fixed code:
#! python3
# print_test_cases.py

for i in range(10000):
    x = int(input())
    if x == 0:
        break
    print('Case ' + str(i+1) + ': ' + str(x))
Buggy code:
for i in range(10000):
    x = input()
    x = int(x)
    
    if x == 0:
        break
    else:
        print("Case", i+1, ":", x)



Fixed code:
y=1
for i in range(10000):
    x=int(input())
    
    if x==0:
        break
    else:
        print('Case',end=' ')
        print(y,end='')
        print(':',end=' ')
        print(x)
        y+=1
Buggy code:
n = 1
while 1:
	x = int(input())
	if x == 0:
		break
	print("Case{0}: {1}" .format(n, x))
	n += 1

Fixed code:
n = 1
while 1:
	x = int(input())
	if x == 0:
		break
	print("Case {0}: {1}" .format(n, x))
	n += 1
Buggy code:
i=0
while 1:
    a=int(input())
    if(a==0)break
    i+=1
    print("Case {0}: {1}".format(i,a))

Fixed code:
i = 0
while 1:
    x = int(input())
    i += 1
    if x == 0: break
    print("Case {0}: {1}".format(i, x))
Buggy code:
i = 1
while True:
    n = int(input())
    if n == 0:
        break
    print("Case ",i,": ",n,sep="")

Fixed code:
i = 1
while True:
    n = int(input())
    if n == 0:
        break
    print("Case ",i,": ",n,sep="")
    i += 1
Buggy code:
i = 1
while True :
	x = int(input())
	if x == 0 :
		break
	print("Case {0}:{1}".format(i,x))
	i+=1

Fixed code:
c = 1
while True:
    x = int(input())
    if x == 0:
        break
    print("Case {}: {}".format(c, x))
    x = 0
    c += 1
Buggy code:
numbers = []
while True:
  x=int(input())
  if x==0:
    break
  numbers.append(x)

for i in range(len(numbers)):
  print("Case",i+1,": ",numbers[i],sep="")



Fixed code:
numbers = []
while True:
  x=int(input())
  if x==0:
    break
  numbers.append(x)

for i in range(len(numbers)):
  print("Case ",i+1,": ",numbers[i],sep="")
Buggy code:
c = 1
while True:
  i = int(input())
  if not i:
    break
  print("Case{}: {}".format(c, i))
  c += 1


Fixed code:
i = 1
while True:
    x = int(input())
    if not x:
        break
    print('Case {}: {}'.format(i, x))
    i += 1
Buggy code:
i = 0
while True:
 i += i+1
 n=int(input())
 if x == 0: break
 print("Case {}: {}".format(i,x))



Fixed code:
i = 1
while True:
 x =int(input())
 if x == 0:
  break
 print("Case {}: {}".format(i,x))
 i = i+1
Buggy code:
i = 0
while True:
    x = int(input())
    if x == 0: 
     break
    i = i + 1
    print("Case " + str(i) + ": " + str(x))



Fixed code:
i = 1
while 1:
    x = int(input())
    if x==0:
        break
    print("Case "+str(i)+":"+" "+str(x))
    i = i + 1
Buggy code:
i = 0
x =input()
while x != 0:
 i += i+1
 print("Case {}: {}".format(i,x))



Fixed code:
i = 1
x = input()
while x != "0":
    print("Case {0}: {1}".format(i, x))
    i += 1
    x = input()
Buggy code:
i=1
while (True):
    a=input()
    if (a=="0"):
        break
    print("Case "+str(i) + ":"+a)
    i+=1

Fixed code:
i=1
while (True):
    a=input()
    if (a=="0"):
        break
    print("Case "+str(i) + ": "+a)
    i+=1
Buggy code:
a=1
while True:
    i=int(input())
    if i==0:
        break
    else:
        print("Case {0:d}: {1:d}".format(a,i))

Fixed code:
a=1
while True:
    i=int(input())
    if i==0:
        break
    else:
        print("Case {0:d}: {1:d}".format(a,i))
        a=a+1
Buggy code:
i = 1
while True:
    instr = input()
    x = int(instr)
    if x == 0:
        break
    else:
        print("Case " + str(i) + ":" + str(x))
    i += 1


Fixed code:
i=1
while True:
    x=int(input())
    if x==0:
        break
    print('Case '+str(i)+': '+str(x))
    i+=1
Buggy code:
a=[]
i=0
while 1 :
	a.append(int(input()))
	i+=1
	if a[i-1] == 0:
		break
for j in range(i-1):
	print("Case  %d:  %d" % (j+1 ,a[j]))


Fixed code:
a=[]
i=0
while 1 :
	a.append(int(input()))
	i+=1
	if a[i-1] == 0:
		break
for j in range(i-1):
	print("Case %d: %d" % (j+1 ,a[j]))
Buggy code:
L=[]
N= 0
while True:
	n= int(input())
	if(n==0):
		break
	L.append(n)
	N= N+1
for x in range(N):
	print("Case",x+1,":",L[x])

Fixed code:
L=[]
N= 0
while True:
	n= int(input())
	if(n==0):
		break
	L.append(n)
	N= N+1
	
for x in range(N):
	print("Case",str(x+1)+":",L[x])
Buggy code:
import sys

for index, line in enumerate(sys.stdin):
    value = int(line.strip())
    print("Case {0}: {1}".format(index+1, value))

Fixed code:
import sys

for index, line in enumerate(sys.stdin):
    value = int(line.strip())
    if value == 0:
        break
    print("Case {0}: {1}".format(index+1, value))
Buggy code:
# itp1_3_b

i = 1

while True:
    x=int(input())
    if x==False:
        break
    print("case {}: {}".format(i,x))
    i+=1



Fixed code:
# itp1_3_b

i = 1

while True:
    x=int(input())
    if x==False:
        break
    print("Case {}: {}".format(i,x))
    i+=1
Buggy code:
i = 1
while True:
    x = int(input())
    if x == 0:
        break
    print("Case {i}: {x}".format(i, x))
    i += 1


Fixed code:
i = 1
while True:
    x = int(input())
    if x == 0:
        break
    else:
        print("Case {}: {}".format(i,x))
        i += 1
Buggy code:
list = []
while True:
    n = int(input())
    if n == 0:
        break
    list.append(n)
for i,n in enumerate(list):
    print('case %i: %i' %(i+1, n))

Fixed code:
list = []
while True:
    n = int(input())
    if n == 0:
        break
    list.append(n)
for i,n in enumerate(list):
    print('Case %i: %i' %(i+1, n))
Buggy code:
from itertools import count
??
for i in count(1):
????????s = input()
??
????????if s == "0":
????????????????break
????????else:
????????????????print("Case {}: {}".format(i, s))

Fixed code:
from itertools import count

for i in count(1):
    s = input()

    if s == "0":
        break
    else:
        print("Case {}: {}".format(i, s))
Buggy code:
i = 0
while True:
    i, n = input(), i+1
    if n == 0:
        break
    print 'Case %d: %d' % (i+1, x)

Fixed code:
i = 1
while True:
  x = int(input())
  if x == 0: break
  print("Case %d: %d"%(i,x))
  i += 1
Buggy code:
import sys

i = 1
while(True):
    x = int(sys.stdin.readline())
    if(x == 0):
        break
    print("Case %d : %d" % (i, x))
    i += 1

Fixed code:
import sys

i = 1
while(True):
    x = int(sys.stdin.readline())
    if(x == 0):
        break
    print("Case %d: %d" % (i, x))
    i += 1
Buggy code:
i = 1
while True:
  n = input()
  if n == 0:
    break
  print("Case {0}: {1}".format(i,n))
  i += 1

Fixed code:
i = 1
while True:
  n = input()
  if n == "0":
    break
  print("Case {0}: {1}".format(i,n))
  i += 1
Buggy code:
import sys
lines = sys.stdin.readlines()
for i in range(lines.length):
    a = int(lines[i])
    if(a == 0):
        break
    else:
        print("Case {0}: {1}".format(i+1, a))


Fixed code:
import sys
lines = sys.stdin.readlines()
for i in range(len(lines)):
    a = int(lines[i])
    if(a == 0):
        break
    else:
        print("Case {0}: {1}".format(i+1, a))
Buggy code:
c = 0
while true:
    x = int(input())
    c += 1
    if x == 0:
        break
    print("Case {}: {}".format(c,x))


Fixed code:
c = 0
while True:
    x = int(input())
    c += 1
    if x == 0:
        break
    print("Case {}: {}".format(c,x))
Buggy code:
a = []
count = 0
while True:
    a.append(int(input()))
    if a[count] == 0:
        break
    count += 1
for i in range(count):
    print('Case %d'%(i+1),':%d'%a[i])


Fixed code:
a = []
count = 0
while True:
    a.append(int(input()))
    if a[count] == 0:
        break
    count += 1
for i in range(count):
    print('Case %d'%(i+1)+': %d'%a[i])
Buggy code:
i = 1
while True:
    a = int(input())
    if(a == 0):
        break
    else :
        print(f'Case{i}: {a}')
    i += 1


Fixed code:
i = 1
while True:
    a = int(input())
    if(a == 0):
        break
    else :
        print(f'Case {i}: {a}')
    i += 1
Buggy code:
i=0
a=list()
while True :
    a=int(input())

    if a == 0:
        break

    i+=1
    print("Case" , i ,":",a)


Fixed code:
i=0
a=list()
while True :
    a=int(input())

    if a == 0:
        break

    i+=1
    print('Case %d: %d'%(i,a))
Buggy code:
import sys
count = 1
While True:
  x = sys.stdin.readline().strip()
  if x == "0":
    break
  print("Case %d: %s" %(count,x))
  count = count + 1

Fixed code:
import sys
count = 1
while True:
  x = sys.stdin.readline().strip()
  if x == "0":
    break
  print("Case %d: %s" %(count,x))
  count = count + 1
Buggy code:
import sys
x = sys.stdin.readlines()

for i, p in enumerate(x):
    if p == 0:
        break
    else:
        print("Case {0}: {1}".format(i+1, p))

Fixed code:
import sys
x = [int(i) for i in sys.stdin.readlines()]

for i, p in enumerate(x):
    if p == 0:
        break
    else:
        print("Case {0}: {1}".format(i+1, p))
Buggy code:
w="test"
a=[]
i=0
while(w!=""):
    w=input()
    a.append(w)
a.remove("")
for k in a:
    i+=1
    print("Case {0}: {1}".format(i,k))

Fixed code:
w=114514
a=[]
i=0
while(w!=0):
    w=int(input())
    a.append(w)
a.remove(0)
for k in a:
    i+=1
    print("Case {0}: {1}".format(i,k))
Buggy code:
n=int(input())
for i in range(10**9)
    print("Case "+str(i+1)+": "+str(n))
    n=int(input())
    if n==0:exit()


Fixed code:
n=int(input())
for i in range(10**9):
    print("Case "+str(i+1)+": "+str(n))
    n=int(input())
    if n==0:exit()