This is the message that I’m currently receiving with my code in VS, every time I try to run the Triple X game in mac. I’ve also included the code bellow.
#include <iostream>
void PrintIntroduction()
//Introduction Text
std::cout << "\nYou need to access the code to be able to win Big Ideas!";
std::cout << "\n\nFind the right codes to shut Big Ideas down!";
void PlayGame()
{
PrintIntroduction();
// Declare 3 number code
const int CodeA = 4;
const int CodeB = 3;
const int CodeC = 2;
const int CodeSum = CodeA + CodeB + CodeC;
const int CodeProduct = CodeA * CodeB * CodeC;
//Print CodeSum and CodeProduct to the terminal
std::cout << std::endl;
std::cout << "+ There are 3 numbers in the code" << std:: endl;
std::cout << "\n+ The numbers add-up to: " << CodeSum;
std::cout << "\n+ The codes multiply to give: " << CodeProduct << std:: endl;
std::cout << CodeProduct << std::endl;
// Store player guess
int GuessA, GuessB, GuessC;
std::cin >> GuessA;
std::cin >> GuessB;
std::cin >> GuessC;
const int GuessSum = GuessA + GuessB + GuessC;
const int GuessProduct = GuessA * GuessB * GuessC;
// Check if the players guess is correct
if (GuessSum == CodeSum && GuessProduct == CodeProduct)
{
std::cout << "\nYou Win!";
}
else
{
std::cout << "\nCarole from Big Ideas here! You've got a 10,000 word essay due for tomorrow! (Oh by the way we'll teach you fuck all in today's lecture) :)";
}
}
int main(true)
{
while (true)
{
PlayGame();
}
return 0;
}