Box Stacking

New puzzle time I suppose, this is one that Ben told me, but it was pretty quick for me to solve since the correct approach uses some logic that I had been trying to use on that last puzzle:
There is a collection of boxes, and the boxes are coloured either red, green, or blue. You are going to be building a triangle of boxes, with a row of 10 on the bottom, 9 in the next row, 8 in the next row, and going all the way up to a single box on top. They are arranged in the sort of obvious triangle pattern, so that each box is on top of exactly two boxes below it.
The color of a box is chosen according to an algorithm, if two neighbouring boxes have the same colour, then the box on top of them is also that colour, if two neighbouring boxes are different colours, then the box on top of them is of the third colour.
Given the colours of the 10 boxes on the bottom row, is there a simple method to determine the colour of the box on top of the triangle?

"A simple method" essentially means one without having to actually go through the process of building the whole triangle.

Yeah, hopefully a simple one, but its sort of neat.

2 comments:

Anonymous said...

Interesting puzzle, but indeed relatively simple. Then again, I needed no techniques from your previous puzzle ;-).

The answer is always the block you would get if you only take the two endpoints (first and last block).

I realized this by representing the colours as numbers modulo 3, and then realizing the block on top of blocks x and y is actually always -x-y. Once you get enough blocks, all the coefficients are divisible by 3 - and only the two endpoints survive.

Kory Stevens said...

Yes, it doesn't actually use any techniques needed for the previous puzzle, but it uses something I had been trying to use, which is adding 3 numbers mod 3, just that that method had never managed to work for me on the previous puzzle.