Thanks
while ((humanTotalScore < 100) && (computerTotalScore < 100))
{
cout << "Play the game. Human goes first: \n";
cout << "Press r to Roll Again or h to Hold. "<< endl;
cin >> rollOrHold;
if ((humanTotalScore > 100) && (computerTotalScore > 100))
{
cout << human << "It is a tie!";
break;
}
else if ((humanTotalScore >100) && (computerTotalScore < 99))
{
cout << human << ", you win!";
break;
}
else if ((humanTotalScore<=99) && (computerTotalScore>=100));
{
cout << "Computer won" << human << ", you lost.";
break;
}
return 0;
}
This post has been edited by no2pencil: 09 October 2010 - 11:07 AM
Reason for edit:: Added Code Tags

New Topic/Question
Reply




MultiQuote







|