A new flag is to be designed with six vertical stripes using some or all of the colours yellow, green, blue and red. Then, evaluate the number of ways this can be done such that no two adjacent stripes have the same?
Any of the 4 colors can be chosen for the first stripe. Any of the remaining 3 colors can be used for the second stripe. The third stripe can again be colored in 3 ways (we can repeat the colour of the first stripe but not use the colour of the second stripe).
Similarly there are 3 ways the flag can be colored is