Add a simple README
This commit is contained in:
parent
43604de9f3
commit
692fe5aed5
8
README.md
Normal file
8
README.md
Normal file
|
@ -0,0 +1,8 @@
|
|||
# Towers of Hanoi
|
||||

|
||||
|
||||
Small repo with two scripts around the popular *Towers of Hanoi* puzzle. I decided to do this after having lunch with some friends which were a few courses ahead of me in CS, and they talked about this puzzle, and I had never thought of solving it with a computer, and I thought it would be a fun and simple CP challenge for myself, so I sat in front of the computer that(this) evening and this is what came out.
|
||||
|
||||
- `game.py`: A simple implementation of the game, which also includes a solver which I created when trying to solve the problem without ever having seen the solution (but it finds the optimal solution nonetheless)
|
||||
|
||||
- `animation.py`: Creates/shows an animation of the optimal solution (in $2^n-1$ moves with $n$ as number of disks). Execute it with `python3 animation.py -h` to see how to use it. It generated the gif on top of this file
|
Loading…
Reference in a new issue