How many numbers with $3,4,5$ together and the $6$ somewhere on the left of $5$?

59 Views Asked by At

How many 9-digit numbers can you write with the numbers from 1 to 9 (without repeating) such that 3,4 and 5 are together (not necessarily in order) and 6 is somewhere on the left of 5?

I've come up with this problem and I'd like to know if you get the same result as I did: $15 120$

I thought about it like this:

  1. $6$ $\color{red}5$ $\color{red}4$ $\color{red}3$ _ _ _ _ _ Here you have ${\color{red}{3!}}\times 5! \times 1$
  2. $6$ _ $5$ $4$ $3$ _ _ _ _ Here you have $3! \times 5! \times 2$

and so on until I got $3!\times 5! \times (1+2+3+4+5+6)=15 120$

Thank you for the input.

2

There are 2 best solutions below

0
On

First think of it as writing $7$-digit numbers with the seven digits $0,1,2,6,7,8,9$ where $6$ comes before $0$ and no repetition is allowed.

There are $\frac12\times7!$ possibilities.

Then afterwards replace digit $0$ by one of the $3$-digits words written with the three digits $3,4,5$ where again no repetition is allowed.

That gives $3!\times\frac12\times7!$ possibilities.

0
On

This may be a strange way to think about it, but it's one possibility...

You might start with the 3, 4, and 5 together part of the problem. There are 3! = 6 ways they can go together: 345, 354, 435, 453, 534, and 543.

You could think of the 3, 4, 5 string as being condensed down to one digit, $X$. Then you're looking for the number of 7-digit strings with 1, 2, $X$, 6, 7, 8, 9 such that 6 comes before $X$. And you'd multiply the number of 7-digit numbers you find by 6 (the number of ways 3, 4, and 5 can be arranged).

Looking at the 7-digit string, there are $C(7, 2) = 21$ ways you can choose the two slots that have the 6 and the 3-4-5. There are then 5 more digits that can be arranged $5! = 120$ ways.

Multiplying everything together we get $3! \cdot C(7,2) \cdot 5! = 6 \cdot 21 \cdot 120 = 15,120$.