4 ms·
Neat! Now implement a solver using Knuth's famous Dancing Links algorithm [1]. [1] https://arxiv.org/abs/cs/0011047 https://arxiv.org/abs/cs/0011047
by csense 3y ago
Neat!
Now implement a solver using Knuth's famous Dancing Links algorithm [1].
[1] https://arxiv.org/abs/cs/0011047 https://arxiv.org/abs/cs/0011047
- RheingoldRiver 3y agoOh wow, I definitely considered a solver but I couldn't think of any reasonable way to do that. The one thing I did implement is a check if empty area === 0 mod 5, which was needed for the 'random board' option, since placing 4 area-1 tiles in an 8x8 grid can only be invalid if one of the areas has area !== 0 mod 4 (at least I think so). That seemed like a first step towards building a solver, but I was still too intimidated by it to go any farther. But I'll take a look at this, thanks for the link!