## Task B-4.2.

The sequence $\left(x_{n}\right)$ is defined by the recursive formula:

$$
x_{1}=1, \quad x_{n+1}=x_{n}+2 n+1, \quad n \geqslant 1 .
$$

Determine $x_{2023}$.
## First Solution.

Let's write down the first $n \geqslant 1$ terms of the sequence:

$$
\begin{gathered}
x_{1}=1 \\
x_{2}=x_{1}+2 \cdot 1+1 \\
x_{3}=x_{2}+2 \cdot 2+1 \\
\vdots \\
x_{n}=x_{n-1}+2 \cdot(n-1)+1
\end{gathered}
$$

By adding the above equations, we get

$x_{1}+x_{2}+x_{3}+\cdots+x_{n-1}+x_{n}=x_{1}+x_{2}+\cdots+x_{n-1}+2 \cdot(1+2+\cdots+(n-1))+n \cdot 1 . \quad 1 \text{ point}$

It follows that

$$
x_{n}=2 \cdot(1+2+\cdots+(n-1))+n \cdot 1
$$

or

$$
x_{n}=2 \cdot \frac{(n-1) \cdot n}{2}+n
$$

from which, by simplifying, we conclude that $x_{n}=n^{2}$.

Therefore, the desired term is $x_{2023}=2023^{2}$.