WEEK 4 Flashcards

1
Q

The inclusion of one or more if statements within an existing if statement.

A

Nested-if

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

This allows us to execute a block of code among many alternatives.

A

Switch Case Statement

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

You can do the same thing with the if…else statement. However, the syntax of this statement is much easier to read and write.

A

Switch Statement

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

The expression is evaluated once and compared with the values of each case label.

A

Switch Case Statement

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

If there is a match, the corresponding code after the matching label is executed. For example, if the value of the variable is equal to constant2, the code after case constant2: is executed until the ____________ statement is encountered.

A

Break Statement

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

If there is no match, the code after ____________ is executed.

A

default:

How well did you know this?
1
Not at all
2
3
4
5
Perfectly