1. To each vertex of a regular 66-gon, we assign one of the numbers 1 or -1. For each segment connecting two of its vertices (a side or a diagonal), we then write down the product of the numbers $v$ at its endpoints and sum all the numbers for the individual segments. Determine the smallest possible and the smallest non-negative value of such a sum.
SOLUTION. Assume that some $k$ vertices $(0 \leqq k \leqq 66)$ of a regular 66-gon are assigned the number 1, and the remaining $66-k$ vertices are assigned the number -1. According to the conditions of the problem, we assign the number 1 to each segment connecting two vertices with the number 1. There are a total of $\frac{1}{2} k(k-1)$ such segments. Similarly, we assign the number 1 to each segment whose both endpoints are assigned the number -1. There are a total of $\frac{1}{2}(66-k)(65-k)$ such segments. Finally, we assign the number -1 to each of the remaining segments (and there are $k(66-k)$ of them).

The value $S$ of the sum of all numbers assigned to individual segments (sides or diagonals of the considered 66-gon) is therefore

$$
\begin{aligned}
S & =\frac{k(k-1)}{2}+\frac{(66-k)(65-k)}{2}-k(66-k)= \\
& =2 k^{2}-2 \cdot 66 k+65 \cdot 33= \\
& =2(k-33)^{2}-33 .
\end{aligned}
$$

We see that $S \geqq-33$ always holds, and equality apparently occurs for $k=33$.

Now we will determine for which $k(0 \leqq k \leqq 66)$ the inequality $S \geqq 0$ is satisfied. These will be the $k$ for which $|k-33| \geqq \sqrt{33 / 2}>4$, so for non-negative values of $S$, it will certainly hold that $S \geqq 2 \cdot 5^{2}-33=17$. Equality occurs when $|k-33|=5$ or $k \in\{28,38\}$.

Conclusion. The examined expression attains its smallest value $S=-33$ for $k=33$. The smallest possible non-negative value of the examined sum is then $S=17$ for $k=28$ or $k=38$.

## GUIDING AND SUPPLEMENTARY PROBLEMS:

N1. Determine the smallest integer value of the expression $U=|x-\sqrt{3}|+\sqrt{5}$, where $x$ is any real number. [The smallest integer value of the expression $U$ is 3 (for $x=\sqrt{3}-\sqrt{5}+3$ or for $x=\sqrt{3}+\sqrt{5}-3$).]

N2. Determine the smallest value of the expression $V=3 x^{2}+4 x+5$, where $x$ is any real number, and also find its smallest integer value. [The smallest possible value of the expression $V$ is $\frac{11}{3}$, which is achieved for $x=-\frac{2}{3}$. The smallest integer value of the examined expression is $V=4$ and is achieved for $x=-1$ or $x=-\frac{1}{3}$.]

N3. Assign one of the numbers 1 or -1 to each vertex of a regular 63-gon. To each of its sides, we assign the product of the numbers at its vertices and sum all the numbers for the individual sides. Find the smallest possible non-negative value of such a sum. [63-B-I-1]

D1. If for $x_{i} \in\{-1,1\}$ it holds that $x_{1} x_{2}+x_{2} x_{3}+\ldots+x_{n-1} x_{n}+x_{n} x_{1}=0$, prove that $n$ is an even number. [Each of the $n$ addends in the given sum is either 1 or -1. Therefore, half of them must be 1 and the other half -1. The number $n$ is thus necessarily even.]