Problem 3. Mario distributed the numbers 1, 2, ..., 8 at the vertices of a cube. When he calculated the sums obtained from each face, he noticed that all the sums were equal.

a) What is the value of each such sum?

b) Find one arrangement of the numbers 1, 2, ..., 8 at the vertices of the cube that has the desired property.
Solution. a) At each vertex of the cube, three edges meet, and the cube has a total of six faces. This means we have six equal sums, and each number appears in the total sum three times. If we denote the desired sum by $S$, then

$$
6 S=3(1+2+\ldots+8)
$$

From this, $S=18$.

b) For example, in the four vertices of the bottom base of the cube, write the numbers 1, 8, 2, 7 (in some circular order), and in the corresponding vertices of the top base, write the numbers 6, 3, 5, 4.