import java.util.NoSuchElementException;
import java.util.Scanner;

public class Main {
    private static int MAX = 10000;
    private static int MIN = 1;
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        try {
            int i = 1;
            while (sc.hasNext()) {
                int x = Integer.parseInt(sc.nextLine());
                if (x == 0) {
                    break;
                }
                if (x > MAX || x < MIN || i > MAX) {
                    System.out.println("Condition is invalid.");
                    return;
                }
                System.out.printf("Case %d: %d\n", i++, x);
            }
        } catch (NoSuchElementException
                | NumberFormatException e) {
            System.out.println(e);
        }
    }
}
 import java.util.NoSuchElementException; NoSuchElementException java.util import java.util.Scanner; Scanner java.util public class Main {
    private static int MAX = 10000;
    private static int MIN = 1;
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        try {
            int i = 1;
            while (sc.hasNext()) {
                int x = Integer.parseInt(sc.nextLine());
                if (x == 0) {
                    break;
                }
                if (x > MAX || x < MIN || i > MAX) {
                    System.out.println("Condition is invalid.");
                    return;
                }
                System.out.printf("Case %d: %d\n", i++, x);
            }
        } catch (NoSuchElementException
                | NumberFormatException e) {
            System.out.println(e);
        }
    }
} Main private static int MAX = 10000; MAX 10000 private static int MIN = 1; MIN 1 public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        try {
            int i = 1;
            while (sc.hasNext()) {
                int x = Integer.parseInt(sc.nextLine());
                if (x == 0) {
                    break;
                }
                if (x > MAX || x < MIN || i > MAX) {
                    System.out.println("Condition is invalid.");
                    return;
                }
                System.out.printf("Case %d: %d\n", i++, x);
            }
        } catch (NoSuchElementException
                | NumberFormatException e) {
            System.out.println(e);
        }
    } main {
        Scanner sc = new Scanner(System.in);
        try {
            int i = 1;
            while (sc.hasNext()) {
                int x = Integer.parseInt(sc.nextLine());
                if (x == 0) {
                    break;
                }
                if (x > MAX || x < MIN || i > MAX) {
                    System.out.println("Condition is invalid.");
                    return;
                }
                System.out.printf("Case %d: %d\n", i++, x);
            }
        } catch (NoSuchElementException
                | NumberFormatException e) {
            System.out.println(e);
        }
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) try {
            int i = 1;
            while (sc.hasNext()) {
                int x = Integer.parseInt(sc.nextLine());
                if (x == 0) {
                    break;
                }
                if (x > MAX || x < MIN || i > MAX) {
                    System.out.println("Condition is invalid.");
                    return;
                }
                System.out.printf("Case %d: %d\n", i++, x);
            }
        } catch (NoSuchElementException
                | NumberFormatException e) {
            System.out.println(e);
        } catch (NoSuchElementException
                | NumberFormatException e) {
            System.out.println(e);
        } NoSuchElementException
                | NumberFormatException e {
            System.out.println(e);
        } System.out.println(e) System.out.println System.out System System.out e {
            int i = 1;
            while (sc.hasNext()) {
                int x = Integer.parseInt(sc.nextLine());
                if (x == 0) {
                    break;
                }
                if (x > MAX || x < MIN || i > MAX) {
                    System.out.println("Condition is invalid.");
                    return;
                }
                System.out.printf("Case %d: %d\n", i++, x);
            }
        } int i = 1; i 1 while (sc.hasNext()) {
                int x = Integer.parseInt(sc.nextLine());
                if (x == 0) {
                    break;
                }
                if (x > MAX || x < MIN || i > MAX) {
                    System.out.println("Condition is invalid.");
                    return;
                }
                System.out.printf("Case %d: %d\n", i++, x);
            } sc.hasNext() sc.hasNext sc {
                int x = Integer.parseInt(sc.nextLine());
                if (x == 0) {
                    break;
                }
                if (x > MAX || x < MIN || i > MAX) {
                    System.out.println("Condition is invalid.");
                    return;
                }
                System.out.printf("Case %d: %d\n", i++, x);
            } int x = Integer.parseInt(sc.nextLine()); x Integer.parseInt(sc.nextLine()) Integer.parseInt Integer sc.nextLine() sc.nextLine sc if (x == 0) {
                    break;
                } x == 0 x 0 {
                    break;
                } break; if (x > MAX || x < MIN || i > MAX) {
                    System.out.println("Condition is invalid.");
                    return;
                } x > MAX || x < MIN || i > MAX x > MAX || x < MIN || i > MAX x > MAX x MAX x < MIN x MIN i > MAX i MAX {
                    System.out.println("Condition is invalid.");
                    return;
                } System.out.println("Condition is invalid.") System.out.println System.out System System.out "Condition is invalid." return; System.out.printf("Case %d: %d\n", i++, x) System.out.printf System.out System System.out "Case %d: %d\n" i++ i x String[] args args public class Main {
    private static int MAX = 10000;
    private static int MIN = 1;
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        try {
            int i = 1;
            while (sc.hasNext()) {
                int x = Integer.parseInt(sc.nextLine());
                if (x == 0) {
                    break;
                }
                if (x > MAX || x < MIN || i > MAX) {
                    System.out.println("Condition is invalid.");
                    return;
                }
                System.out.printf("Case %d: %d\n", i++, x);
            }
        } catch (NoSuchElementException
                | NumberFormatException e) {
            System.out.println(e);
        }
    }
} public class Main {
    private static int MAX = 10000;
    private static int MIN = 1;
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        try {
            int i = 1;
            while (sc.hasNext()) {
                int x = Integer.parseInt(sc.nextLine());
                if (x == 0) {
                    break;
                }
                if (x > MAX || x < MIN || i > MAX) {
                    System.out.println("Condition is invalid.");
                    return;
                }
                System.out.printf("Case %d: %d\n", i++, x);
            }
        } catch (NoSuchElementException
                | NumberFormatException e) {
            System.out.println(e);
        }
    }
} Main
import java.util.NoSuchElementException;
import java.util.Scanner;

public class Main {
    private static int MAX = 10000;
    private static int MIN = 1;
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        try {
            int i = 1;
            while (sc.hasNext()) {
                int x = Integer.parseInt(sc.nextLine());
                if (x == 0) {
                    break;
                }
                if (x > MAX || x < MIN || i > MAX) {
                    System.out.println("Condition is invalid.");
                    return;
                }
                System.out.printf("Case %d: %d\n", i++, x);
            }
        } catch (NoSuchElementException
                | NumberFormatException e) {
            System.out.println(e);
        }
    }
}

