First solution.

If we denote the number of students by $x$, then there exist natural numbers $k, l$, and $m$ such that

$$
\begin{aligned}
& x=8 k+1 \\
& x=7 l+2 \\
& x=6 m+5
\end{aligned}
$$

From the first two conditions, we get:

$$
8 k=7 l+1 \Rightarrow 8(k-1)=7(l-1) \Rightarrow k=7 a+1 \text { and } l=8 a+1, a \in \mathbb{N} . \quad \text { (4 points) }
$$

From the second and third conditions, we have:

$$
7 l=6 m+3 \Rightarrow 7(l-3)=6(m-3) \Rightarrow l=6 b+3 \text { and } m=7 b+3, b \in \mathbb{N} \text {. (4 points) }
$$

From this, we get

$$
\begin{aligned}
8 a+1 & =6 b+3 \\
8 a & =6 b+2 \\
4(a-1) & =3(b-1)
\end{aligned}
$$

Therefore, there exists a positive integer $p$ such that $a-1=3 p, \text { i.e., } a=3 p+1$.

It follows that,

$$
x=8 k+1=8 \cdot[7 a+1]+1=8 \cdot[7 \cdot(3 p+1)+1]+1=168 p+65
$$

The condition $100<x<300$ is satisfied only by $p=1$, i.e., $x=233$.

Second solution.

Since $x=8 k+1$, the possible numbers are:

$$
\begin{aligned}
x= & 105,113,121,129,137,145,153,161,169,177,185,193,201, \\
& 209,217,225,233,241,249,257,265,273,281,289,297 .
\end{aligned}
$$

(10 points)

Of these numbers, the condition $x=7 l+2$ is satisfied by

$$
x=121,177,233,289
$$

Of these numbers, the condition $x=6 m+5$ is satisfied only by

$$
x=233
$$

Therefore, there are a total of 233 students in the second grades.
1. Determine all complex numbers $z$ such that:

$$
\operatorname{Re} z=5 \cdot \operatorname{Im} z \quad \text{and} \quad|z-(a+i b)|=5
$$

where $a$ and $b (a>b)$ are the solutions of the quadratic equation

$$
(x-1)^{2}+3(x-1)-4=0
$$

## Solution.

The equation is already written as a quadratic equation in $(x-1)$.

We get $(x-1)_{1,2}=\frac{-3 \pm 5}{2}, \text{i.e.} x_{1}=-3, x_{2}=2$.

Note: By rearranging, we get the equation $x^{2}+x-6=0$ which can also be easily solved.

We are looking for a complex number $z=x+i y$.

From the first condition, we have $x=5 y$.

The second condition can be written in the form $|x+y i-2+3 i|=5$.

(5 points)

From here, we get:

$$
\begin{gathered}
|5 y+y i-2+3 i|=5 \\
(5 y-2)^{2}+(y+3)^{2}=25 \\
13 y^{2}-7 y-6=0
\end{gathered}
$$

The solutions to this quadratic equation are $y_{1}=1$ and $y_{2}=-\frac{6}{13}$.

Then we get $x_{1}=5$ and $\quad x_{2}=-\frac{30}{13}$.

Thus, we have obtained two complex numbers $z_{1}=5+i$ and $z_{2}=-\frac{30}{13}-\frac{6}{13} i$.

(5 points)

- In the second grades of a certain school, there are between 100 and 300 students. During one arrangement, the principal intended to line them up in rows. If he placed them in 8 rows, one student would be left over. If he placed them in 7 rows, two students would be left over. If he placed them in 6 rows, 5 students would be left over. How many students are there in total in the second grades of this school?