1. A warehouse has coffee packed in bags of 15 kg and 8 kg. How many bags of coffee in total does the warehouseman need to prepare to weigh out 1998 kg of coffee, with the number of 8 kg bags being the smallest possible?
Solution. Let $x$ be the number of bags weighing 15 kg, and $y$ be the number of bags weighing 8 kg. We get the equation $15 x + 8 y = 1998$. $8(x + y) + 7 x = 1998$, let $x + y = k$,

$8 k + 7 x = 1998$,

$7(k + x) + k = 1998$, let $k + x = t$,

$7 t + k = 1998$, $k = 1998 - 7 t$. Substitute into (2), $x = 8 t - 1998$.

Substitute into (1), $y = 2 \cdot 1998 - 15 t$.

Since $x > 0, y > 0$, then $250 \leq t \leq 266$. To have the smallest number of 8 kg coffee bags, then $t = 266$. Then accordingly $x = 130, y = 6$.

130 and 6 bags, a total of 136 bags.

Answer: 136.