18. For each natural $n$, which is not a perfect square, the number of values of the variable $x$ is calculated, for which both numbers $x+\sqrt{n}$ and $x^{2}+param1 \cdot \sqrt{n}$ are natural numbers less than param2. Find the total number of such values of $x$.

| param1 | param2 | answer |
| :---: | :---: | :---: |
| 18 | 200 |  |
| 20 | 210 |  |
| 22 | 250 |  |
| 24 | 300 |  |
| 26 | 330 |  |
18. For each natural $n$, which is not a perfect square, the number of values of the variable $x$ is calculated, for which both numbers $x+\sqrt{n}$ and $x^{2}+param1 \cdot \sqrt{n}$ are natural numbers less than param2. Find the total number of such values of $x$.

| param1 | param2 | answer |
| :---: | :---: | :---: |
| 18 | 200 | 108 |
| 20 | 210 | 99 |
| 22 | 250 | 117 |
| 24 | 300 | 143 |
| 26 | 330 | 148 |