76 974
Assignments Done
Successfully Done
In June 2019

Answer to Question #23977 in C++ for Nourh

Question #23977
Write code that simulates the roll of two dice. If the two dice have the same value, output the statement "Doubles. Roll again." Otherwise, print "Your turn is over.";
Expert's answer
using namespace std;
& bool f(int a){
if(a>-1 && a<101)
return true;
return false;

int main (){
int a=1,b=1;

a =rand() % (6)+1;
b=rand() % (6)+1;
cout<<a<<" "<<b<<"\n";

system("PAUSE"); &

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!


No comments. Be first!

Leave a comment

Ask Your question

Privacy policy Terms and Conditions