Discrete Mathematics – Counting Increasing Four-Digit Integers

discrete mathematics

How to find the number of distinct four digit numbers that are increasing or decreasing?

The correct answer is $2{9 \choose 4} + {9 \choose 3} = 343$. How to get there?

Best Answer

For every collection of $4$ distinct digits, there is a unique way to arrange the digits so that they are decreasing, and a unique way to arrange them so that they are increasing. This gives $2 \binom{10}{4}$ different sequences that are increasing or decreasing, but not all correspond to a four-digit number. For increasing sequences, you cannot have $0$ as a first digit. This rules out $\binom{9}{3} = 84$ possibilities. So the total is $2(210) - 84=336 \neq 343$...?