Subjects combinatorics

Digit Sequence Arrangements Cda8Be

Step-by-step solutions with LaTeX - clean, fast, and student-friendly.

Search Solutions

Digit Sequence Arrangements Cda8Be


1. **Problem Statement:** Find the number of ways to arrange the digits of 111222333 such that the resulting number contains the sequence 123 or 321. 2. **Given:** The digits are 1,1,1,2,2,2,3,3,3. 3. **Total permutations without restriction:** Since there are 9 digits with repetitions, total permutations are $$\frac{9!}{3!3!3!} = \frac{362880}{6 \times 6 \times 6} = 1680.$$ 4. **Define events:** - Let $A$ be the set of permutations containing the sequence 123. - Let $B$ be the set of permutations containing the sequence 321. 5. **Counting $|A|$ (permutations with 123):** Treat the sequence 123 as a single block. - The block 123 uses one 1, one 2, and one 3. - Remaining digits: 1,1,2,2,3,3 (two 1s, two 2s, two 3s). - Total elements to arrange: the block + 6 remaining digits = 7 elements. - The 6 remaining digits have repetitions: 1 appears twice, 2 appears twice, 3 appears twice. - Number of permutations: $$\frac{7!}{2!2!2!} = \frac{5040}{8} = 630.$$ 6. **Counting $|B|$ (permutations with 321):** By symmetry, same as $|A|$, so $$|B| = 630.$$ 7. **Counting $|A \cap B|$ (permutations containing both 123 and 321):** - Both sequences 123 and 321 must appear. - Each sequence uses one 1, one 2, and one 3. - Since digits are limited, the two sequences must be disjoint blocks. - Treat 123 and 321 as two separate blocks. - Remaining digits after removing digits used in both blocks: 1,2,3 (one each left). - Total elements to arrange: 2 blocks + 3 single digits = 5 elements. - The 3 single digits are distinct (1,2,3), so no repetition. - Number of permutations: $$5! = 120.$$ 8. **Use Inclusion-Exclusion Principle:** $$|A \cup B| = |A| + |B| - |A \cap B| = 630 + 630 - 120 = 1140.$$ **Final answer:** There are $$1140$$ such permutations.