Coloring Book

Chris bought a coloring book for his sister Jensene. The first page is a diagram

cute little snowman cute little snowman

But Chris forgot to buy more color pencils! At the moment, he only has Red , Blue and Green color pencils. How many different snowman can Jensene colors such that no two adjacent space has the same color?


The answer is 192.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

A straightforward bash using python:

answer = 0
for a1 in range(1,4):
    for a2 in range(1,4):
        for a3 in range(1,4):
            for a4 in range(1,4):
                for a5 in range(1,4):
                    for a6 in range(1,4):
                        for a7 in range(1,4):
                            if a1!=a4 and a2!=a4 and a3!=a4 and a4!=a5 and a6!=a5 and a7!=a5:
                                answer+=1
print (answer)

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...