[Solved] How would I program an algorithm to solve this puzzle? [closed]
You can see this as a graph theory problem (http://en.wikipedia.org/wiki/Graph_theory). Each given state of your puzzle is a Vertice of the graph, and each light switching is an edge that takes the Graph to another state. Given a starting state, if you expand your graph breadth-first, your will find the sortest solution (http://en.wikipedia.org/wiki/Breadth-first_search). It is … Read more