#include
int main()
{
//this will be the welcome and intro message to tripleX game
std::cout << "you are a professional hacker breaking into sever ";
std::cout << std::endl;
std::cout << "enter the correct pin to destroy the server";
std::cout << std::endl;
std::cout << "if you sucessfully destroy server you win ";
std::cout << std::endl;
std::cout << "you receice reward of $1000 on every level......" << std::endl;
//declaring 3 number code need to destroy server
const int CodeA = 2;
const int CodeB = 3;
const int CodeC = 6;
//sum and product
const int CodeSum = CodeA + CodeB + CodeC;
const int CodeProduct = CodeA * CodeB * CodeC;
//it is at the initialising stage sum and product to terminal for printing
std::cout << std::endl;
std::cout << "*there are 3 numbers in the code " << std::endl;
std::cout << "*the code will be add up to: " << CodeSum << std::endl;
std::cout << "*the product of the code is: " << CodeProduct << std::endl;
int GuessA, GuessB, GuessC;
std::cin >> GuessA;
std::cin >> GuessB;
std::cin >> GuessC;
scroll
int GuessSum = GuessA + GuessB + GuessC;
int GuessProduct = GuessA * GuessB * GuessC;
if(GuessSum == CodeSum && GuessProduct == CodeProduct)
{
std::cout << "congrats $1000 cr. ";
}
else
{
std::cout << "you lost the alarm are trigered *****ERROR**CODE****you bank= $0000 ";
}
return 0;