<|instruction|>
Solve the below problem. The solution should start with an abridged problem statement. Then key observations. Then full solution based on the observations. Then C++ and Python implementations with comments.

467. Chessmaster
Time limit per test: 0.25 second(s)
Memory limit: 262144 kilobytes
input: standard
output: standard



Ivan Petrovich and Petr Ivanovich enjoy playing chess, especially Ivan Petrovich. Each time he loses regular weekend game in chess, from superfluity of feelings he takes the board and breaks it into separate black and white fields. Well, things were going that way before Petr Ivanovich, frustrated by weekly breakages of his chessboards, replaced usual chessboard by titanic one. Now it was not so easy even to scratch it! But Ivan Petrovich didn't become flustered and, in affective state after usual unsuccessful play, ordered a powerful laser which could burn accurate perfectly round holes through the chessboard.

Only after the laser was delivered Ivan Petrovich realized to his horror that it was not powerful enough: instead of having diameter of a beam equal to the diagonal of a chessboard, his laser had diameter equal to the length of its side! This means that he will be unable to destroy the whole chessboard in one shot, and will have to use the laser several times. But Ivan Petrovich's pension is not large enough to cover bills for electricity after using the laser too frequently, so now he is puzzled with natural question: if he wishes to destroy at least P percents of the chessboard surface, what is the minimum number of laser shots that he have to do?

Help Ivan Petrovich in answering this important and difficult question. And remember: you may shoot only in direction orthogonal to the surface of chessboard, and it is not allowed to move (probably) peeled off parts. Chessboard has the usual form of a perfect square.

Input
Input file contains up to 100 non-negative integer numbers, each on a separate line — percentage of the board P that Ivan Petrovich wants to destroy. Each P will not exceed 100, of course.

Output
For every P in the input file write to the output file on a separate line required minimum number of laser shots. Follow format shown in the example below.

Example(s)
sample input
sample output
1
2
Case #1: 1
Case #2: 1

<|response|>
1. Abridged problem statement  
   You have a unit‐side square (area = 1). Each laser shot removes a circular hole of radius 0.5 (area = π/4 ≈ 0.7854). Given an integer P (0 ≤ P ≤ 100) denoting the percent of the square’s area you want to destroy, compute the minimum number of shots required so that at least P% of the square is removed. Read up to 100 values of P (one per line) until EOF, and for the k-th input Pₖ output  
   “Case #k: x”  
   where x is the minimum shots.

2. Key observations  
   • One shot removes area A₁ = π/4 ≈ 0.7854 ⇒ 78.54% of the square.  
     ⇒ If P ≤ 78, one shot suffices.  
   • Two shots, placed optimally, can cover about 95% of the square ⇒ if 78 < P ≤ 95, need 2 shots.  
   • Three shots can reach ≈99% coverage ⇒ if 95 < P ≤ 99, need 3 shots.  
   • To hit exactly 100%, three radius-0.5 circles can’t cover the entire square ⇒ need 4 shots.  
   • If P = 0, no shots are needed.

3. Full solution approach  
   Since P is an integer in [0,100] and the coverage thresholds for 1,2,3,4 shots are known, we simply compare P against these breakpoints in O(1) per query. Maintain a case counter, read each P until EOF, determine the shot count by a few if-else checks, and print in the required format.

4. C++ implementation with detailed comments  
```cpp
#include <bits/stdc++.h>
using namespace std;

int main() {
    ios::sync_with_stdio(false);
    cin.tie(nullptr);

    int P;
    int caseNum = 1;
    // Read percentages until end of file
    while ( (cin >> P) ) {
        int shots;
        if (P == 0) {
            // No coverage required
            shots = 0;
        }
        else if (P <= 78) {
            // One circle of area ≈78.54% suffices
            shots = 1;
        }
        else if (P <= 95) {
            // Two circles can cover up to ≈95%
            shots = 2;
        }
        else if (P <= 99) {
            // Three circles can cover up to ≈99%
            shots = 3;
        }
        else {
            // Only four such circles can guarantee full 100%
            shots = 4;
        }

        // Output in the required format
        cout << "Case #" << caseNum << ": " << shots << "\n";
        ++caseNum;
    }

    return 0;
}
```

5. Python implementation with detailed comments  
```python
import sys

def min_shots(P):
    """
    Return minimum number of radius-0.5 circles needed to destroy at least
    P percent of a unit square.
    """
    if P == 0:
        # No area needs to be destroyed
        return 0
    if P <= 78:
        # One circle covers ~78.54%
        return 1
    if P <= 95:
        # Two circles cover ~95%
        return 2
    if P <= 99:
        # Three circles cover ~99%
        return 3
    # To reach full 100%, need four circles
    return 4

def main():
    case_num = 1
    # Read each line from standard input
    for line in sys.stdin:
        line = line.strip()
        if not line:
            continue  # skip empty lines
        P = int(line)
        result = min_shots(P)
        # Print "Case #k: x"
        print(f"Case #{case_num}: {result}")
        case_num += 1

if __name__ == "__main__":
    main()
```