Battleship

Key Term

  • Protocol:  An agreed-upon set of rules that specify the behavior of some system

Objective: Develop a protocol for Battleship in a group of 3.

  • List all of the information that you will need to communicate in order to play Battleship. How will you express each piece of information in binary? (i.e. a player’s turn, hit, miss, etc.)

Instructions

  • Make a table that organizes and explains the protocol. Don’t worry about coming up with a “correct” protocol — just one that works!
    • What do the bits represent?
  • The final document should contain a table and an explanation of how the protocol works (i.e. rules). It should provide enough information for another group to implement the protocol.
  • Organize the table based on the following sections. Clearly label these sections:
    • Sequence of Turns
      • Who will go first? Who will go next? In what order?
    • Coordinates
      • How will you specify how players will make a guess (e.g. coordinates)?
    • Results
      • How will you specify a guess (hit, miss, or sunk)?
      • How do you indicate game over?
    • Error handling
      • How will you handle invalid inputs or communication failures?

Tips

  • While developing your protocol, here are some questions and suggestions to think about:
    • Remember that ultimately you are making a communication protocol for a computer to read, so if it’s hard for a human to decipher, but would be easy to describe for a computer, that’s fine.
    • A message you send over the Internet is just a string of 0s and 1s — so your protocol should indicate how the bits work (i.e. what is the binary representation?)
    • You can also invent other rules or standards of play that would help make the protocol work well.
    • Think about using numeric addresses rather than people’s names.
    • Think about what else you can communicate with binary to reduce the total number of bits. How “efficient” can you make your message? How small can you make the size of a message?
    • You might consider testing out your protocol with the Internet Simulator to see if it’s viable.

Skills assessed: effective problem-solving, critical thinking, creativity, communication, and collaboration


Submission