End Game

Learn to set up the game’s end.

What we have

We already have almost a complete game, but after checking the winner of each round, we have to display the results at the end. This is our inventory of already created functions:

// Function to display game introduction and rules
void displayIntroductionAndRules() {
    cout << "Welcome to Rock-Paper-Scissors game!\n" << endl;
    cout << "The rules of the game are simple:" << endl;
    cout << "1. Rock beats scissors" << endl;
    cout << "2. Scissors beats paper" << endl;
    cout
...