import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.List;

class Main {

	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		List<Integer> inputList = new ArrayList<Integer>();
		while(true) {
			if (inputList.size() > 10000) {
				break;
			}
					
			int num = Integer.parseInt(br.readLine());
			
			if (num == 0) {
				break;
			}
			
			if (!(num >= 1 && num <= 10000)) {
				throw new IllegalArgumentException();
			}
				
			inputList.add(num);
		}
		
		for (int i = 0; i < inputList.size(); i++) {
			System.out.println("Case " + (i + 1) + ": " + inputList.get(i));
		}
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io import java.util.ArrayList; ArrayList java.util import java.util.List; List java.util class Main {

	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		List<Integer> inputList = new ArrayList<Integer>();
		while(true) {
			if (inputList.size() > 10000) {
				break;
			}
					
			int num = Integer.parseInt(br.readLine());
			
			if (num == 0) {
				break;
			}
			
			if (!(num >= 1 && num <= 10000)) {
				throw new IllegalArgumentException();
			}
				
			inputList.add(num);
		}
		
		for (int i = 0; i < inputList.size(); i++) {
			System.out.println("Case " + (i + 1) + ": " + inputList.get(i));
		}
	}
} Main public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		List<Integer> inputList = new ArrayList<Integer>();
		while(true) {
			if (inputList.size() > 10000) {
				break;
			}
					
			int num = Integer.parseInt(br.readLine());
			
			if (num == 0) {
				break;
			}
			
			if (!(num >= 1 && num <= 10000)) {
				throw new IllegalArgumentException();
			}
				
			inputList.add(num);
		}
		
		for (int i = 0; i < inputList.size(); i++) {
			System.out.println("Case " + (i + 1) + ": " + inputList.get(i));
		}
	} main {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		List<Integer> inputList = new ArrayList<Integer>();
		while(true) {
			if (inputList.size() > 10000) {
				break;
			}
					
			int num = Integer.parseInt(br.readLine());
			
			if (num == 0) {
				break;
			}
			
			if (!(num >= 1 && num <= 10000)) {
				throw new IllegalArgumentException();
			}
				
			inputList.add(num);
		}
		
		for (int i = 0; i < inputList.size(); i++) {
			System.out.println("Case " + (i + 1) + ": " + inputList.get(i));
		}
	} BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) List<Integer> inputList = new ArrayList<Integer>(); inputList new ArrayList<Integer>() while(true) {
			if (inputList.size() > 10000) {
				break;
			}
					
			int num = Integer.parseInt(br.readLine());
			
			if (num == 0) {
				break;
			}
			
			if (!(num >= 1 && num <= 10000)) {
				throw new IllegalArgumentException();
			}
				
			inputList.add(num);
		} true {
			if (inputList.size() > 10000) {
				break;
			}
					
			int num = Integer.parseInt(br.readLine());
			
			if (num == 0) {
				break;
			}
			
			if (!(num >= 1 && num <= 10000)) {
				throw new IllegalArgumentException();
			}
				
			inputList.add(num);
		} if (inputList.size() > 10000) {
				break;
			} inputList.size() > 10000 inputList.size() inputList.size inputList 10000 {
				break;
			} break; int num = Integer.parseInt(br.readLine()); num Integer.parseInt(br.readLine()) Integer.parseInt Integer br.readLine() br.readLine br if (num == 0) {
				break;
			} num == 0 num 0 {
				break;
			} break; if (!(num >= 1 && num <= 10000)) {
				throw new IllegalArgumentException();
			} !(num >= 1 && num <= 10000) (num >= 1 && num <= 10000) num >= 1 num 1 num <= 10000 num 10000 {
				throw new IllegalArgumentException();
			} throw new IllegalArgumentException(); new IllegalArgumentException() inputList.add(num) inputList.add inputList num for (int i = 0; i < inputList.size(); i++) {
			System.out.println("Case " + (i + 1) + ": " + inputList.get(i));
		} int i = 0; int i = 0; i 0 i < inputList.size() i inputList.size() inputList.size inputList i++ i++ i {
			System.out.println("Case " + (i + 1) + ": " + inputList.get(i));
		} {
			System.out.println("Case " + (i + 1) + ": " + inputList.get(i));
		} System.out.println("Case " + (i + 1) + ": " + inputList.get(i)) System.out.println System.out System System.out "Case " + (i + 1) + ": " + inputList.get(i) ": " "Case " + (i + 1) + ": " + inputList.get(i) "Case " (i + 1) i 1 ": " inputList.get(i) inputList.get inputList i String[] args args
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.List;

class Main {

	public static void main(String[] args) throws IOException {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		List<Integer> inputList = new ArrayList<Integer>();
		while(true) {
			if (inputList.size() > 10000) {
				break;
			}
					
			int num = Integer.parseInt(br.readLine());
			
			if (num == 0) {
				break;
			}
			
			if (!(num >= 1 && num <= 10000)) {
				throw new IllegalArgumentException();
			}
				
			inputList.add(num);
		}
		
		for (int i = 0; i < inputList.size(); i++) {
			System.out.println("Case " + (i + 1) + ": " + inputList.get(i));
		}
	}
}