Combinatorics (1 Viewer)

yiaghertop

New Member
Joined
Jul 26, 2024
Messages
9
Gender
Undisclosed
HSC
2026
Four girls and Four boys are to stand in a row. Find the number of arrangements if Boys and Girls alternate and John is next to Sally. Any ideas?

Answer: 504
 

f7eeting

Active Member
Joined
Aug 29, 2024
Messages
89
Gender
Female
HSC
2026
hi! the way id do this is id consider arranging alternating boys and girls first which would look like:
4!x4!x2 (where multiplying for 2 accounts for the separate cases where either a boy could be first or a girl)
then, since we're told that a specific boy and a specific girl MUST sit next to each other, id remove them from the sample space of boys and girls, leaving us with:
3!x3!x2
but since there are numerous ways we can arrange john and sally together, you have to account for that as well, so i multiply 3!x3! by 7 (this can be seen easily if you draw out 8 boxes and see how many ways you can shuffle 2 objects across)
and overall i get:
3!x3!x7x2
and to break it down:
3!x3! (arranges the other boys and girls that are not john or sally) x7 (arranging the possible positions john and sally could be in) x 2 (counts for the case where a boy is first or a girl)

and while i was doing this, i was thinking about counting the cases where john and sally could be switched but then realised you cant do that because then it wouldnt alternate between boys and girls. a bit trivial but just putting it out there incase it helps clarify anything
hope this helps!
 

yiaghertop

New Member
Joined
Jul 26, 2024
Messages
9
Gender
Undisclosed
HSC
2026
hi! the way id do this is id consider arranging alternating boys and girls first which would look like:
4!x4!x2 (where multiplying for 2 accounts for the separate cases where either a boy could be first or a girl)
then, since we're told that a specific boy and a specific girl MUST sit next to each other, id remove them from the sample space of boys and girls, leaving us with:
3!x3!x2
but since there are numerous ways we can arrange john and sally together, you have to account for that as well, so i multiply 3!x3! by 7 (this can be seen easily if you draw out 8 boxes and see how many ways you can shuffle 2 objects across)
and overall i get:
3!x3!x7x2
and to break it down:
3!x3! (arranges the other boys and girls that are not john or sally) x7 (arranging the possible positions john and sally could be in) x 2 (counts for the case where a boy is first or a girl)

and while i was doing this, i was thinking about counting the cases where john and sally could be switched but then realised you cant do that because then it wouldnt alternate between boys and girls. a bit trivial but just putting it out there incase it helps clarify anything
hope this helps!
Thank you so much, I really appreciate your help!!
 

Luca26

Member
Joined
Sep 13, 2025
Messages
44
Gender
Male
HSC
2026
Start with the case where the alternating pattern is B-G-B-G-B-G-B-G:
  • Place John in position 1 (1 way)
    • in which case Sarah has to be position 2 (1 way)
    • other three boys can be positioned in 3! ways
    • and same for other three girls
  • So, John in position 1 gives 1 x 1 x 3! x 3! = (3!)2 arrangements
  • Now, John could be in any of the other three B positions (3 ways)
    • in which case Sarah has to be in one of two positions adjacent to John (2 ways)
    • other three boys can be positioned in 3! ways
    • and same for other three girls
  • So, John not in position 1 gives 3 x 2 x 3! x 3! = (3!)3 arrangements
  • So, this case yields (3!)2 + (3!)3 = (3!)2(1 + 3!) = 7 x 62 = 252 arrangements
The alternative case with arrangements G-B-G-B-G-B-G-B will, by placing Sarah analogously to John above, yield 252 arrangements

Thus, there are a total of 504 arrangements.
 

justletmespeak123

Probably jerking off to haram arabic twinks
Joined
Oct 14, 2024
Messages
282
Location
15 Budapest St Rooty Hill, New South Wales
Gender
Male
HSC
2024
Sure! Let's break it down step by step.

Step 1: Total Number of Positions

Since the boys and girls must alternate, the arrangement will look like this:


  • Boy, Girl, Boy, Girl, Boy, Girl, Boy, Girl (or vice versa, starting with a girl).

This gives us two possible patterns:


  1. Boy, Girl, Boy, Girl, Boy, Girl, Boy, Girl
  2. Girl, Boy, Girl, Boy, Girl, Boy, Girl, Boy

But, since we are not yet concerned with which pattern (starting with a boy or a girl), let's just focus on the alternating pattern for now.

Step 2: Number of Ways to Arrange Boys and Girls

There are 4 boys and 4 girls, and they need to be arranged in these alternating positions.


  • Boys can be placed in 4 specific spots (since the alternating pattern requires the boys to be in certain places). The number of ways to arrange the boys in these spots is ( 4! ) (4 factorial).
  • Girls can be placed in the remaining 4 spots. The number of ways to arrange the girls is also ( 4! ) (4 factorial).

So, without any further restrictions, the total number of ways to arrange the boys and girls would be:
[
4! \times 4!
]

Step 3: Account for John and Sally

Now, we need to incorporate the condition that John is next to Sally.


  • Treat John and Sally as a single "block" or "unit" because they must be next to each other. This means we now have 3 boys and 3 girls to arrange (excluding John and Sally).
  • John and Sally can be arranged within their "block" in 2 ways: John can be on the left or Sally can be on the left.

Now, we need to arrange the remaining 3 boys and 3 girls in the remaining positions. Since we still need to alternate, we can follow the same logic as before:


  • There are 3 boys and 3 girls to be arranged in alternating positions. The number of ways to do this is ( 3! \times 3! ).
Step 4: Total Number of Arrangements

Now, we can calculate the total number of arrangements by multiplying the possibilities together:


  1. Number of ways to arrange the 3 remaining boys and 3 remaining girls: ( 3! \times 3! ).
  2. Number of ways to arrange John and Sally within their "block": 2 ways (John can be left or right).
  3. Total number of ways to arrange the blocks of boys and girls, including John and Sally: ( 3! \times 3! \times 2 ).

Thus, the total number of arrangements is:
[
(3! \times 3! \times 2) \times 4! \times 4!
]


Now, let's calculate this:
[
3! = 6, \quad 4! = 24
]
So,
[
(6 \times 6 \times 2) \times (24 \times 24) = 72 \times 576 = 41472
]

Final Answer:

The total number of arrangements is 41,472.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Top