upvote
When you say play perfectly do you mean by exhausting all possibilities? Or is there some way to deduce ahead of time whether the RNG will put you in an impossible situation.
reply
The way the game is seeded, it's 100% deterministic. So if you can scan enough potential moves / second, it's very easy to infinitely play the game at a fast rate.

Shockingly, Claude was able to find the exact random generators that the js library uses, list out all of the differences between the languages that might impact the replays (like rounding being treated differently), and include those differences in the simulation. Claud then back-tested on a huge number of games using the original implementation as a golden set generator.

reply
I started by pulling the game source locally and doing some initial testing with a few solvers. I ended up having Claude make a 1-for-1 perfect sim of the original game using rust with some optimizations. The original engine was able to check around 180 moves/s and the rust port was hitting 2,150 moves/s.

After that, I tested a few solvers. Single Player Monte Carlo Tree Search seemed promising, but didn't do as well as I expected. A simple beam search does appear to go infinitely pretty easily.

reply