The document describes the process of playing a game of battleship, where a player guesses the location and orientation of hidden ships on a grid. It involves calculating probability fields to determine the most likely guesses, pursuing in directions, switching directions 180 degrees if a hit isn't found, and checking if the current ship has been sunk or if any partially sunk ships remain on the board.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0 ratings0% found this document useful (0 votes)
2K views
Battleship Algorithm
The document describes the process of playing a game of battleship, where a player guesses the location and orientation of hidden ships on a grid. It involves calculating probability fields to determine the most likely guesses, pursuing in directions, switching directions 180 degrees if a hit isn't found, and checking if the current ship has been sunk or if any partially sunk ships remain on the board.