A simple command-line implementation of the classic Hasboro game.
git clone git@github.com:ccashwell/battleship
cd battleship
chmod +x ./battleship
./battleship [options]
--help
(or-h
) — Print helpful usage information.--cheat
(or-c
) — Show the positions of ships on the gameboard.--verbose
(or-v
) — Print gameboard state after each turn.
- No Tests: Due to time constraints I did not implement any testing.
- One-sided Gameplay: Due to time constraints I did not implement an AI player.
- External Dependencies: While not necessary, I used 3 external libraries.
While this is just a simple example implementation, you're welcome to offer any contributions. Just clone the repo, make some commits and open a pull request.