ICS3U(Java): Introduction to Computer Science

Unit 2: Introduction to Programming

Activity 4: Selection Control Structure

Answer


Question

Can you tell which output statement will be displayed in the console when score contains the value 3? What about a score of 6?

 
Answer
  • Pretty good is displayed when then score is 1, 2, 3, 4 or 5
  • Great is displayed for scores 6, 7, 8, 9 and 10.

Close Window