placeholder

sudoku-in-python-packaging

Absurdly clever hack by [konsti](https://github.com/konstin): solve a Sudoku puzzle entirely using the Python package resolver! First convert the puzzle into a `requirements.in` file representing the current state of the board: …

Click to view the original at simonwillison.net

Hasnain says:

This was a fun little hack.

“So the trick here is that the Python dependency resolver (now lightning fast thanks to uv) reads those dependencies and rules out every package version that represents a number in an invalid position. The resulting version numbers represent the cell numbers for the solution.”

Posted on 2024-10-22T06:55:10+0000