ret = []

while True:

    n = eval(input())

    if n == 0:

        break

    ret += [n]



for i, x in enumerate(ret):

    print('Case %d: %d' % (i+1, x))
ret = []

while True:

    n = eval(input())

    if n == 0:

        break

    ret += [n]



for i, x in enumerate(ret):

    print(('Case %d: %d' % (i+1, x)))
ret = []
while True:
    n = eval(input())
    if n == 0:
        break
    ret += [n]
for i, x in enumerate(ret):
    print("Case %d: %d" % (i + 1, x))

ret = []
while True:
    n = eval(input())
    if n == 0:
        break
    ret += [n]
for i, x in enumerate(ret):
    print(("Case %d: %d" % (i + 1, x)))

-    print("Case %d: %d" % (i + 1, x)) +    print(("Case %d: %d" % (i + 1, x)))