+0  
 
0
132
2
avatar

Find the number of positive integers that satisfy both the following conditions:

Each digit is a 1 or a 2

The sum of the digits is 10

 Feb 14, 2023
 #1
avatar
-1

Let $a$ be the number of digits equal to 1 and $b$ be the number of digits equal to 2. Then we have the following conditions:

$a+b$ is the total number of digits, and $a+2b=10$ since the sum of the digits is 10.

Solving for $a$ in terms of $b$ gives $a=10-2b$, so we need to find the number of positive integer values of $b$ such that $1 \le b \le 5$ (since $a$ and $b$ must be positive).

Substituting $a=10-2b$ into $a+b$ gives $10-b$, so the total number of digits is between 5 and 10.

Therefore, the number of positive integers satisfying both conditions is the sum of the number of solutions for $b$ from 1 to 5, which is:

$$(10-2\cdot1)+(10-2\cdot2)+(10-2\cdot3)+(10-2\cdot4)+(10-2\cdot5)=5+4+3+2+1=\boxed{15}.$$

 Feb 14, 2023
 #2
avatar
-1

22222 , 112222 , 121222 , 122122 , 122212 , 122221 , 211222 , 212122 , 212212 , 212221 , 221122 , 221212 , 221221 , 222112 , 222121 , 222211 , 1111222 , 1112122 , 1112212 , 1112221 , 1121122 , 1121212 , 1121221 , 1122112 , 1122121 , 1122211 , 1211122 , 1211212 , 1211221 , 1212112 , 1212121 , 1212211 , 1221112 , 1221121 , 1221211 , 1222111 , 2111122 , 2111212 , 2111221 , 2112112 , 2112121 , 2112211 , 2121112 , 2121121 , 2121211 , 2122111 , 2211112 , 2211121 , 2211211 , 2212111 , 2221111 , 11111122 , 11111212 , 11111221 , 11112112 , 11112121 , 11112211 , 11121112 , 11121121 , 11121211 , 11122111 , 11211112 , 11211121 , 11211211 , 11212111 , 11221111 , 12111112 , 12111121 , 12111211 , 12112111 , 12121111 , 12211111 , 21111112 , 21111121 , 21111211 , 21112111 , 21121111 , 21211111 , 22111111 , 111111112 , 111111121 , 111111211 , 111112111 , 111121111 , 111211111 , 112111111 , 121111111 , 211111111 , 1111111111 , Total =  89 such positive integers

 Feb 14, 2023

5 Online Users

avatar
avatar
avatar
avatar