Geekdad Puzzle of the Week Solution: Holiday Lights and Splices

This week’s puzzle presented an easy solution. Unfortunately, the easy solution was not the right solution. Let’s start with the puzzle recap and then the solution.

Gus Gauss likes to hack his holiday lights together himself. The last thing he has to decorate is the fence around the front yard and his design calls for red and green alternating lights. Unfortunately for him he doesn’t have a single string of lights long enough to do the job but he does have twelve sections of lights that he can splice together that can be used. Here are the strings of lights he has:

String 1:

R — G —R — G —R — G —R — G —R — G —

String 2:

G —R — G —R — G —

String 3:

G —R — G —R — G —R — G —R — G — R —

String 4:

R — G —R — G —R —

String 5:

R — G —R — G —R — G —R — G —R — G —

String 6:

G —R — G —R — G —

String 7:

G —R — G —R — G —R — G —R — G — R —

String 8:

R — G —R — G —R — G —R — G —R — G —

String 9:

G —R — G —R — G —

String 10:

G —R — G —R — G —R — G —R — G — R —

String 11:

R — G —R — G —R —

String 12:

R — G —R — G —R — G —R — G —R — G — R — G —R — G —R —

The lights are of a unique type and require special splices. The cost to splice a green light to a red light is 25 cents (0.25 dollars) and to splice a red light to a green light is 22 cents (0.22 dollars). This means the cost of splicing String 1 to the end of String 2 is is 22 cents but to splice string 2 to the end of string 1 costs 25 cents.

What is the cheapest way for Gus to create the string he needs to finish his decorating?

To simplify things, if he joins two green lights with a red light it costs 22 cents and joining two reds with a green costs 25 cents.

The straightforward solution is to flip the strings around and arrange them so you are always using a 22 cent splice. There are 12 strings with 11 ends to be connected. This gives a total of $2.42 cents. Pretty straightforward… but there is another way. By cutting string 4 or 11 into separate bulbs you end up with 11 strings that have 10 ends to be connected. This week’s winner Will Etienne did it this way ….

Yep! Will saved 13 cents and made $50.00 in the form of a ThinkGeek Gift Certificate. Come back this coming week and Garth will have some more fun for your puzzling pleasure. I have to go make the interns dress as elves and start putting together presents for me.

Dave Giancaspro is a Network Engineer in NYC with a wife and two kids. When he's not working he builds stuff, does card tricks and tries to get to the gym. Sometimes all at once.