Everybody remembers this paper-and-pencil game from childhood: Tic-Tac-Toe, also known as Noughts and crosses or Xs and Os. A single mistake usually costs you the game, but thankfully it is simple enough that most players discover the best strategy quickly.
Simple.Tic.Tac.Toe.mp4
The example below shows how your program should work. Notice that after Enter the coordinates: comes the user input.
--------- | | | | | | --------- Enter the coordinates: 2 2 --------- | | | X | | | --------- Enter the coordinates: 2 2 This cell is occupied! Choose another one! Enter the coordinates: two two You should enter numbers! Enter the coordinates: 1 4 Coordinates should be from 1 to 3! Enter the coordinates: 1 1 --------- | O | | X | | | --------- Enter the coordinates: 3 3 --------- | O | | X | | X | --------- Enter the coordinates: 2 1 --------- | O | | O X | | X | --------- Enter the coordinates: 3 1 --------- | O | | O X | | X X | --------- Enter the coordinates: 2 3 --------- | O | | O X O | | X X | --------- Enter the coordinates: 3 2 --------- | O | | O X O | | X X X | --------- X wins