4. Let $n=\overline{a b c}$ be a three-digit number, where $a, b, c$ are the lengths of the sides that can form an isosceles (including equilateral) triangle. The number of such three-digit numbers $n$ is $\qquad$.

 untranslated part: $\qquad$
When the waist length is 1, there is only one three-digit number $\overline{a b c}$; when the waist length is 2, there are 7 three-digit numbers $\overline{a b c}$; when the waist length is 3, there are 13 three-digit numbers $\overline{a b c}$; when the waist length is 4, there are 19 three-digit numbers $\overline{a b c}$; when the waist length is $5,6,7,8,9$, there are 25 three-digit numbers $\overline{a b c}$ each.
Therefore, the total number of three-digit numbers $\overline{a b c}$ is $125+40=165$.