I am making a simple rock paper scissors game (key word-making. Notice I haven't set up interactions for the numbers yet) and my compiler says there is a problem with the last two lines of code.
#include <cstdlib>
#include <iostream>
usingnamespace std;
int main(int argc, char *argv[])
{
//welcomes user and asks for thier name
char name[25];
cout << "Let's play rock paper scissors.\n";
cout << "Enter your name\n";
gets(name);
cout << "\nOkay " << name << ", Lets begin\n";
//Rules
cout << "Enter your 1 for rock, 2 for paper, or 3 for scissors\n";
cout << "Enter 0 to tally up scores\n";
system("PAUSE");
//Begin Game
for(;;)
{
int choice;
bool recognize = false;
cout << "\nRock\n";
cout << "Paper\n";
cout << "Scissors\n";
cout << "Shoot!!!\n\n";
cin >> choice;
int CPUchoice = (rand()%3)+1;
if (choice = 1||2||3||0)
{recognize = true;}
if (recognize == false)
{cout << "Sorry, that is not a recognizable command";}
system("PAUSE");}
}
return 0;
}