Use all 3 digits? Like, 102 would be lowest, 201 highest?
Or do you mean: 1,2,10,11,12,20,21,22 ...... 221,222?
How many positive integers under 1000 use only the digits 0, 1, 2 when written?
I assume that leading zeros are not allowed.
We could write them out and count them . . . The answer is 26.
We can reason it out like this . . .
There are only 2 one-digit numbers: 1 and 2.
For two-digit numbers: there are 2 choices for the first digit
. . and 3 choices for the second.
There are: 6 two-digit numbers.
For three-digit numbers: there are 2 choices for the first digit,
. . 3 choices for the second,
. . and 3 choices for the third.
There are: 18 three-digit numbers.
Therefore, there are: . such numbers.