• #### how many ways can 5 people (1, 2, 3, 4, 5) be assigned to 3 rooms (A, B

From henhanna@gmail.com@21:1/5 to All on Sun Jul 3 10:33:21 2022
how many ways can 5 people (1, 2, 3, 4, 5) be assigned to
3 rooms (A, B, C) when...

(1) No room can be empty
(2) One room can be empty

pls wait a few days before posting answers or hints.

--- SoupGate-Win32 v1.05
* Origin: fsxNet Usenet Gateway (21:1/5)
• From Edward Murphy@21:1/5 to henh...@gmail.com on Sun Jul 3 14:00:06 2022
On 7/3/2022 10:33 AM, henh...@gmail.com wrote:

how many ways can 5 people (1, 2, 3, 4, 5) be assigned to
3 rooms (A, B, C) when...

(1) No room can be empty
(2) One room can be empty

[spoiler space]

Without any restrictions, there are 3^5 = 243 ways to assign the people.

With restriction (2), only 3 of those ways are invalid:
a) All five people are assigned to room A
b) All five people are assigned to room B
c) All five people are assigned to room C
so the other 240 ways are valid.

With restriction (1), those 3 ways are invalid, plus:

* 2^5 ways to assign them to rooms A and B, minus 2 ways to assign
all five to just one of those rooms (since those ways were already
excluded above). So 2^5 - 2 = 30 total.

* Similarly, 30 ways to assign to rooms A and C (but not already
excluded), and 30 ways to assign them to rooms B and C (but not