main = showCaseN 1

showCaseN :: Int -> IO ()
showCaseN n = do
    m <- getLine
    if m == "0" then
        return ()
    else do
        putStrLn $ "Case " ++ (show n) ++ ": " ++ m
        showCaseN (n + 1)

