subject

What does the following code segment do?
var isseven =false;
while ( isseven==false )
{
var roll1=math. floor(math. random( )*6+1);
var roll2=math. floor(math. random( )*6+1);
if(roll1 + roll2 ==7)
{
isseven = true;
alert(roll1 +"--"+roll2);
}
}
it keeps generating two random numbers of any values until the sum of the two numbers is 7.
it keeps generateing two random numbers between 1 and 6, and adds up the two numbers.
it keeps generating two random numbers between 1 and 6, until the sum of the two numbers is 7.
it keeps generating two random numbers between 1 and 6, then check if the sum of the two numbers is 7.

ansver
Answers: 1

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 11:50
You have written, as part of a school assignment, a research paper on the solar system. you want to share this paper on your school website. on which type of server will you upload it?
Answers: 1
question
Computers and Technology, 23.06.2019 13:30
Stops: using the information learned in this course, explain three things you will not do when driving. a. b. c. explain why you will not do these things when driving. starts: using the information learned in this course, explain three things you will do when driving. a. b. c. explain why you will do these particular things when driving. explain one thing you will stop doing as a passenger. explain one thing you will start doing as a passenger.
Answers: 3
question
Computers and Technology, 23.06.2019 16:30
How to do this programming flowchart?
Answers: 3
question
Computers and Technology, 24.06.2019 00:50
Which player type acts on other players? a. killer b. achiever c. explorer d. socializer
Answers: 1
You know the right answer?
What does the following code segment do?
var isseven =false;
while ( isseven==false )<...
Questions
question
Geography, 06.03.2021 07:10
question
Mathematics, 06.03.2021 07:10
question
Mathematics, 06.03.2021 07:10
question
Mathematics, 06.03.2021 07:10
question
Mathematics, 06.03.2021 07:10
question
History, 06.03.2021 07:10
question
Mathematics, 06.03.2021 07:10
question
Mathematics, 06.03.2021 07:10
question
Spanish, 06.03.2021 07:10
Questions on the website: 13722361