## Task A-2.4.

A stick is a cuboid of dimensions $1 \times 1 \times 2$, and a container is a body obtained by removing a cube $1 \times 1 \times 1$ from a cuboid of dimensions $3 \times 3 \times 2$ at the center of one of the two halves $3 \times 3 \times 1$.

If it is allowed to use as many sticks and containers as needed, how many of these bodies are required to assemble a cube of dimensions $303 \times 303 \times 303$ without gaps or overlaps? The bodies may be rotated.
## Solution.

Assume we have constructed the cube using $a$ containers and $b$ rods. Since a container is made up of 17 unit cubes, and a rod of two, we have $17 a + 2 b = 303^3$. We want to minimize the expression $a + b$.

Since a container is made up of more unit cubes than a rod, to construct the cube using as few such bodies as possible, we need to find the construction that uses the maximum number of containers.

For a certain container, consider the hole created by removing a $1 \times 1 \times 1$ cube from the middle of one of its halves. The hole of each container that is inside the large cube is also inside that cube, so it must be filled by some body. This hole can only be covered by a rod.

On the other hand, each rod can fill the hole of at most two containers. Therefore, the inequality $a \leqslant 2 b$ must hold.

Substituting this inequality into the initial equation, we get

$$
303^3 = 17 a + 2 b \geqslant 18 a
$$

from which we have

$$
a \leqslant \frac{303^3}{18} = \frac{3090903}{2}
$$

Since $a$ is a natural number, we conclude additionally that

$$
a \leqslant \frac{3090902}{2} = 1545451
$$

We will prove that it is possible to construct the cube using exactly 1545451 containers.

Let's call a block a body of dimensions $3 \times 3 \times 4$ made up of two containers and one rod that fills their two holes. First, using $101 \cdot 101 \cdot 75$ such blocks, we fill the lower part of the cube of dimensions $303 \times 303 \times 300$.

After that, from the remaining part of the cube of dimensions $303 \times 303 \times 3$, we fill the left part of the cube of dimensions $303 \times 300 \times 3$ using 101.75 blocks, and then from the remaining part of dimensions $303 \times 3 \times 3$, we use 75 blocks to cover another part of the cube of dimensions $300 \times 3 \times 3$.

The remaining part to cover is a cube of dimensions $3 \times 3 \times 3$. Place a container with a hole facing upwards at its bottom, and place one rod in that hole. In the highest row of the remaining eight spaces around the last rod, arrange four more rods.

In total, we have used

$$
101 \cdot 101 \cdot 75 + 101 \cdot 75 + 75 = 772725
$$

blocks. For their creation, 1545450 containers and 772725 rods were needed. After that, we used one more container and 5 rods. The total number of containers used is 1545451, which is indeed the maximum number of containers we can use according to the earlier part of the proof.

The total number of bodies used is $1545451 + 772730 = 2318181$, and this is the smallest number of bodies we need to construct the entire cube of dimensions $303 \times 303 \times 303$.