I have a question similar to the one posed here.
How many ways can 4 things of type A, 4 things of type B, and 4 things of type C be arranged so no two things of the same type are seated together?
This is similar to the question "If you have n boys and m girl, how many ways can you seat them so that no one is sitting next to the same gender?" but with three types of objects instead of two?
My best idea is 6 * 4!4!4! because there are six possible unique combinations of types A, B, and C. ABC ACB BAC BCA CAB CBA and there are 4 of each type. I haven't been able to find an example of this problem that deals with more than 2 types of things and it seems to fit the formula of m! * n1!n2!...nm! where m is the number of sets and n is the number of things in those sets.
Is my thinking correct or does that formula not describe this situation? If not, what formula would?
A general solution for $n$ types of indistinguishable objects having $m$ each is
$$f(n,m) = n!.((n-1).(n-1)!)^{m-1}$$
To obtain this, you have to arrange the objects in such a way that there are $m$ continuous groups of each of the $n$ objects placed one after the other. The only constraint is that the last element of one group should be different from the first element of the next group.
Number of ways of arranging the first group = $n!$
Now, for a fixed first group, the number of choices for the first element is $(n-1)$, to prevent repetition at the boundary of two groups. Then you are free to permute the rest of the $(n-1)$ objects. This process will repeat for $(m-1)$ times