i = 1

n = 1

while n != 0:

	n = int(input())

	if n == 0:

		continue

	print("Case %d: %d" %(i, n))

	i += 1
cases = []

n = 1

while n != 0:

	n = int(input())

	if n == 0:

		continue

	cases.append(n)





for i in range(len(cases)):

	print("Case %d: %d" %(i + 1, cases[i]))
i = 1
n = 1
while n != 0:
    n = int(input())
    if n == 0:
        continue
    print("Case %d: %d" % (i, n))
    i += 1

cases = []
n = 1
while n != 0:
    n = int(input())
    if n == 0:
        continue
    cases.append(n)
for i in range(len(cases)):
    print("Case %d: %d" % (i + 1, cases[i]))

-i = 1 +cases = [] -    print("Case %d: %d" % (i, n)) -    i += 1 +    cases.append(n) +for i in range(len(cases)): +    print("Case %d: %d" % (i + 1, cases[i]))