import Data.List
main = poyo 1
poyo cnt = do
  str<-getLine
  let [a]=map read $ words str ::[Int]
  if(a==0)
    then return ()
    else do
      putStrLn $ "Case "++(show cnt)++": "++(show a)
      poyo$cnt+1