Three teams (Team A, Team B, and Team C) are participating in a trivia contest. Let scoreA represent the number of correct questions for Team A, scoreB represent the number of correct questions for Team B, and scoreC represent the number of correct questions for Team C. Assuming no two teams get the same number of correct questions, what code segments correctly displays the team with the highest number of correct questions?

Respuesta :

fichoh

To make comparison between a set of variables, the if-else statement is usually employed, Hence, the correct code segment which displays the team with the highest number of correct questions is the option A.

  • First it checks if ScoreA > ScoreB ; - - - #1st block
  • If True ; then check if ScoreA > ScoreC ;

  • Then TeamA will be the highest, if otherwise then it will be TeamC

  • If the 1st block is false, then ScoreB > ScoreA;
  • then check if ScoreB > ScoreC ;
  • Then TeamB will be the highest, if otherwise then it will be TeamC

Hence, the correct option is A.

Learn more : https://brainly.com/question/25675806

Ver imagen fichoh
Ver imagen fichoh

Answer:

A

Explanation: