## Task A-1.5.

Martin assigns each of the 12 edges of a cube a number, either 1 or -1. Then he assigns to each of the six faces of the cube the product of the 4 numbers on the edges of that face. Finally, Martin sums all 18 numbers assigned to the edges and faces of the cube.

What is the smallest sum Martin can achieve?
## First Solution.

Consider the five numbers associated with one face and the four edges that bound it. Note that their sum can be at least -3.

Indeed, if all the numbers associated with the edges are -1, then their product is 1, so the sum is -3. If at least one of the numbers on the edges is not -1, then the sum is an odd number greater than -5, hence at least -3.

Let $s$ be the sum of all numbers on the faces of the cube, and $b$ be the sum of all numbers on the edges. We are interested in the minimum value of $s+b$.

Consider the six sums obtained by adding the five numbers associated with one face and the four edges that bound it.

In this sum, each number associated with the faces of the cube appears once, and each number associated with the edges of the cube appears twice.

Thus,

$$
s+2 b \geqslant 6 \cdot(-3)=-18
$$

Clearly, $s \geqslant-6$, so we conclude that $2 s+2 b \geqslant-24$, or that $s+b \geqslant-12$.

We will also show that it is indeed possible to achieve $s+b=-12$.

On the cube $A B C D E F G H$, assign the number -1 to the edges $\overline{A B}, \overline{G C}$, and $\overline{E H}$, and the number 1 to all other edges. This way, each face of the cube is assigned the number -1, so the total sum is indeed -12.

![](https://cdn.mathpix.com/cropped/2024_05_30_5917997a941cee38e810g-06.jpg?height=657&width=643&top_left_y=1325&top_left_x=638)