Combinatorics doesn't mean always using C(n,r). What it always requires is careful thinking, and choosing tools from a toolbox that also includes permutations, multiplication, addition, subtraction, and some interesting tricks. Don't think you just have to pick n and r and you'll be done!
Combinations, C(n,r), would mean choosing a subset of r from a set of n, without regard to arrangement. Here, the problem is all about arrangements! The "multiplication principle" is the way to go.
I'd think of the problem as filling in three blanks, _ _ _. How many ways are there to fill in the first? Once you've done that, how many ways are there to fill in the second? And so on.
Note that if the flags weren't labeled, we'd consider them indistinguishable, and we'd be filling in the blanks with mere colors, R, W, B. Since they are labeled, they are distinguishable, and we can just call the flags 1 through 12, where 1 - 5 are red, 6 - 9 are white, and 10 - 12 are blue.
I tried to write it out. Probably wrong but I am trying to figure it out.
If I have the Red (1) then next would be White (6,7,8, or 9) and then after that, it would be (10-12) blue.
1 then 6 and then any combination 10,11,12 = 3 possibilites
1 then 7 and then any combination 10,11,12 = 3 possibilites
1 then 8 and then any combination 10,11,12 = 3 possibilites
1 then 9 and then any combination 10,11,12 = 3 possibilites
= 12 possibilites
If I have the Red (2) then next would be White (6,7,8, or 9) and then after that, it would be (10-12) blue.
2 then 6 and then any combination 10,11,12 = 3 possibilities
2 then 7 and then any combination 10,11,12 = 3 possibilities
2 then 8 and then any combination 10,11,12 = 3 possibilities
2 then 9 and then any combination 10,11,12 = 3 possibilities
= 12 possibilities
If I have the Red (3) then next would be White (6,7,8, or 9) and then after that, it would be (10-12) blue.
3 then 6 and then any combination 10,11,12 = 3 possibilities
3 then 7 and then any combination 10,11,12 = 3 possibilities
3 then 8 and then any combination 10,11,12 = 3 possibilities
3 then 9 and then any combination 10,11,12 = 3 possibilities
= 12 possibilities
If I have the Red (4) then next would be White (6,7,8, or 9) and then after that, it would be (10-12) blue.
4 then 6 and then any combination 10,11,12 = 3 possibilities
4 then 7 and then any combination 10,11,12 = 3 possibilities
4 then 8 and then any combination 10,11,12 = 3 possibilities
4 then 9 and then any combination 10,11,12 = 3 possibilities
= 12 possibilities
If I have the Red (5) then next would be White (6,7,8, or 9) and then after that, it would be (10-12) blue.
5 then 6 and then any combination 10,11,12 = 3 possibilities
5 then 7 and then any combination 10,11,12 = 3 possibilities
5 then 8 and then any combination 10,11,12 = 3 possibilities
5 then 9 and then any combination 10,11,12 = 3 possibilities
= 12 possibilities
Added all together 12 + 12 + 12 + 12 + 12 = 60 possibilities.
Am I on the right track or not close? There is probably an easier way, but I'm really trying.