I’ve replaced all of the instances of std::endl; with \n but I found that there’s no longer a line after the last hint - my code seems identical to Gavin’s but I can’t see how to add a new line to the end…
// Print sum and product to the terminal
std::cout << "+ There are 3 numbers in the code\n";
std::cout << "\n+ The codes add up to: " << CodeSum;
std::cout << "\n+ The codes multiply to give: " << CodeProduct;
You are a secret agent breaking into a secure room…
You need to enter the correct codes to continue…
-
There are 3 numbers in the code
-
The codes add up to: 9
-
The codes multiply to give: 24<- Guess is being prompted here
<-Instead of here