1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Nikolay [14]
3 years ago
13

In a certain game, the integer variable bonus is assigned a value based on the value of the integer variable score.

Advanced Placement (AP)
2 answers:
Bingel [31]3 years ago
5 0

Answer:

See Explanation

Explanation:

The options are not properly presented; hence, they can't be used to answer this question

First, we need to analyze the conditions:

  • score > 100 implies bonus = 2 * score
  • score between 50 and 100 implies bonus = score
  • score < 50 implies bonus = 0

Writing the above as programming instructions, we have:

if(score > 100){//This represents the first condition

bonus = 2 * score;

}

else if(score >=50 && score<=100){//This represents the second

bonus = score;

}

else{//This represents the last condition

bonus = 0;

}

<em>Note that, we assume that all variables have been declared</em>

<em>The comments (//) were used for explanation purpose</em>

marishachu [46]3 years ago
4 0

Answer:

A and D

Explanation:

In a certain game, the integer variable bonus is assigned a value based on the value of the integer variable score.

If score is greater than 100 bonus is assigned a value that is 10 times score

•If score is between 50 and 100 inclusive, bonus is assigned the value of score.

If score is less than se, bonus is assigned a value of 0

Which of the following code segments assigns bonus correctly for all possible integer values of score?

Select two answers

Answer : A and D

You might be interested in
What is not a characteristic of money
Alex777 [14]
Money is a substance that is acceptable as a medium of exchange for goods and services and can further be used to settle debt.

Money is well defined by its functions and characteristics.

6 0
3 years ago
1. Nangako si June sa kaniyang OFW na nanay na di na magpupuyat
Genrish500 [490]

Answer:

Pag sasabihin sya o mapapalo or grounded

3 0
3 years ago
Bukod sa mga na banggit na mga salik. anong salik ang iyong maidadagan
Gekata [30.6K]

Where is your question?

Explanation:

8 0
3 years ago
All of the following are characteristics of AP courses compared with regular high school courses except:
Lisa [10]
Letter C is the correct answer
5 0
3 years ago
Read 2 more answers
Does anyone know this one if so please help me out
scZoUnD [109]

Answer:

i think that its B

Explanation:

5 0
3 years ago
Other questions:
  • What is the connection between a credit report and a credit score?
    12·2 answers
  • THIS IS A SCIENCE QUESTION
    14·1 answer
  • Integrate sec(4x)tan(4x)dx
    5·1 answer
  • What is the name for the highest amount a policyholder pays for deductibles, coinsurance, and copayments? A. benefit maximum B.
    13·1 answer
  • Native Americans call the river muhheakantuk the river that flows both ways. Why do you think this is?
    9·1 answer
  • Annabelle drops a flat metal disk into a slot and then pulls a lever. After repeating this process three times, several flat met
    10·1 answer
  • What are the three categories of teratogens?
    7·1 answer
  • Entonces entonces entonces entonces entonces entonces entonces entonces, Entonces entonces entonces entonces entonces entonces e
    15·2 answers
  • I think it’s b but im not sure
    7·2 answers
  • Which statement accurately describes industry today?
    15·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!