Activity 1.7.1.
- To refactor sequential
if
statements, when they have the same body, we can always conjoin their conditions using||
. - No! Not always
- We can conjoin the conditions of sequential if statements with the same body using
||
when those conditions are exclusive. - Correct!
- Sequential if statements with mutually exclusive conditions, can be refactored to use
else if
structure and when their body is also the same, they can be conjoined using||
. - Correct!
- if we have sequential if statements where each statement prints a message, and conditions are NOT mutually exclusive, multiple if conditions may evaluate to true in one run.
- Correct!
Which of the following options summarize the main points in the video?
Select all that apply.