Post

C++ Tic-Tac-Toe App

Aims for Tic-Tac-Toe:

The primary aim of the project is to put into practice some of the C++ I am relearning along with that which I can recall from the dark, distant past, and with some influence from a Python version I built a while ago.

Outline:

  1. Simple console app, using the python Tic-Tac-Toe I built in the Python training course in 2020-21.
  2. Against the computer. A random function determines who has first move as X.
  3. Prompts the challenger for name to make it sound a little more friendly.
  4. Computer move randomly picks one of the remaining free cells.
  5. At the end of the game, we ask the challenger if they would like another game.

So, What did I learn?

  1. As well as refreshing some C++ I was able learn a little about the newer features of the C++ language.
  2. This was also an opportunity to learn a little about the build process of the app using both CMake and Ninja.
  3. With CMake I learned a little about the configuration of cross-platform building of applications.
  4. With Ninja I also learned about the part that the Generator plays in the build process.
    • I want to learn more about the use of CMake within the GitHub CI/CD pipleline.

GitHub Repo:

The source code, along with the documentation for setup, build, etc. can be found in my GitHub.

As always, happy to hear your thoughts…

Modified By: Martin Thompson

Last Modified: September 4, 2024-11:30:00

This post is licensed under CC BY 4.0 by the author.