subject

Result ← 1 IF(score1 > 500)
{
result ← result + 1
IF(score2 > 500)
{
result ← result + 1
}
ELSE
{
result ← result + 2
}
}
ELSE
{
result ← result + 5
IF(score2 > 500)
{
result ← result + 1
}
ELSE
{
result ← result - 1
}
}
 
 

 If the value of score1 is 505 and the value of score2 is 250, what will be the value of result after the code segment is executed?

 

If the value of score1 is 350 and the value of score2 is 200, what will be the value of result after the code segment is executed?

ansver
Answers: 3

Another question on Advanced Placement (AP)

question
Advanced Placement (AP), 25.06.2019 01:30
Which two organisms in the food web would most likely be affected by a decrease in producers, or the plants, at the bottom base of the food web?
Answers: 1
question
Advanced Placement (AP), 25.06.2019 19:30
Marcy is a very good math student, but she seldom studies for tests. as a result, her grade has dropped this semester. this is an example wasting talent getting distracted allowing others to set goals
Answers: 1
question
Advanced Placement (AP), 26.06.2019 11:00
Micheal wants to estimate how much it will cost him each month to own and maintain his car. which of the following costs should not be included in the calculations? routine maintenance? dealer fees? gas? loan payments? wouldn't it be dealer fees? ? idk in advance! : )
Answers: 1
question
Advanced Placement (AP), 26.06.2019 21:10
All of the following demonstrate ways that learning is tied to experience except
Answers: 2
You know the right answer?
Result ← 1 IF(score1 > 500)
{
result ← result + 1
IF(score2 > 500)
{
Questions
question
Chemistry, 16.11.2020 04:30
question
Social Studies, 16.11.2020 04:30
question
English, 16.11.2020 04:30
question
Mathematics, 16.11.2020 04:30
question
Mathematics, 16.11.2020 04:30
Questions on the website: 13722360