Console implementation of the classic "Bulls and Cows" game in C++ with a client–server architecture and operating system mechanisms (shared memory, inter‑process communication). The project was originally created as a course work in operating systems.
- Console "Bulls and Cows" game.
- Separation into two applications:
clientandserver. - Shared types and utilities extracted into
include/(SharedMemory,SharedTypes, etc.). - CMake-based build system.
- Repository structure suitable for further development and experimentation.
- Language: C++
- Build system: CMake
- OS concepts: shared memory, inter‑process communication, synchronization
- Environment: console applications
client/– client application (Client, clientmain.cpp).server/– server application (Server,Game, servermain.cpp).include/– shared headers and implementations (SharedMemory,SharedTypes, etc.).CMakeLists.txt– root CMake configuration.
From the project root directory:
mkdir build
cd build
cmake ..
cmake --build .After a successful build, separate client and server executables will be generated (exact paths depend on your CMake configuration).
- Build the project (see above).
- Start the server in one console.
- Start the client in another console and connect to the server.
- Play "Bulls and Cows" through the console interface.
- Practical experience with OS concepts: shared memory and inter‑process communication.
- Designing a small but complete client–server system in C++.
- Organizing a C++ project with modular structure and CMake build system.