Lisa wants to check the day of the week and execute different code for each day. Which control structure would be the most appropriate for her use?

  • For Loop
  • If-Else Statements
  • Switch Statement
  • While Loop
For Lisa's scenario, the most appropriate control structure is the "Switch Statement." A switch statement allows you to evaluate a single expression against multiple possible constant values, making it ideal for executing different code blocks based on the day of the week.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *