- What is Towers of Hanoi?(Ctrl + click) the link
- Does this work on Linux?
- Sadly no, due to libraries used in the code.
- Does this work on Windows
- Yes, below instructions are provided.
- Download zip to Downloads
- Unzip TowersOfHanoi-master
- right-click & extract here
- Stuff needed for gcc/g++(Ctrl + click) the link
- run & install
- Video on how to install the compilers Compiler Installation Tutorial(Ctrl + click) the link
- If you have installed them once, you don't need to again
- Press together:
Win + R
- type & enter:
cmd
- type & enter:
cd Downloads
to change directory to your Downloads - type & enter:
cd TowersOfHanoi-master
- type & enter:
g++ main.cpp -o run
- Read
How to play
before playing - type & enter:
run
- Setup
- You are asked how many pieces & pegs you want to play with.
- You may pick (1 - too many) pieces
- You may pick (1 - 9) pegs
- Movement:
- Pegs are considered numbered from left to right, starting at 1
- First number entered represents the peg from which you are taking the top piece
- Second number entered represents the peg from which you place the taken piece
- Pegs are considered numbered from left to right, starting at 1
- Objective
- Move the stack of pieces from the far left peg to the far right peg
- Notes
- The number of moves it takes to win grows exponentially as you play with more pieces