Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I think solving any of these can be reduced to a max-flow problem, and thus it is efficiently solvable.


Many of the levels have been designed so that if you follow the path of least resistance to solve them, you will always be left with one line that wont connect. Thats the true puzzle part of the game, and that's the aspect that makes me think it's difficult to solve without resorting to brute force.


I think you are right, it's harder than I thought.

The problem can in fact be modeled with a graph in which you need to find vertex-disjoint paths between pairs of vertices (s1,t1), (s2,t2), and so on, but this problem seems not to be reducible to max-flow, instead it is NP-hard.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: