CS 159 (Lab 7)

0.0(0)
studied byStudied by 0 people
GameKnowt Play
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/14

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

15 Terms

1
New cards

According to course standards, you are required to use { and } with all if constructs.

True

2
New cards

When the selection is based on a range of values, or the condition is not integral, we use the

else-if for our multiway selection needs.

True

3
New cards

The dangling else logical error can be corrected by indenting the if and else the same number of spaces.

False

4
New cards

The conditional expression has three operands and two operators.

True

5
New cards

The control expression that follows the keyword switch may be an integer or character

expression.

True

6
New cards

Each switch case label is the keyword case followed by a constant expression inside of single quotes.

False

7
New cards

The break statement causes the program to jump out of the switch statement.

True

8
New cards

The course standards limit the use of the break statement to only switch statements.

True

9
New cards

The case label represents an integral type that is a possible result of the selection condition

expression.

True

10
New cards

No two switch case labels can represent the same constant expression value.

True

11
New cards

It is a logical error to associate two switch case labels with a common set of actions.

False

12
New cards

The maximum number of actions that can be associated with a switch case label is one.

False

13
New cards

Negative logic refers to any expression that begins with a NOT operator or that contains multiple NOT operators within.

True

14
New cards

Complementing a condition is one way to potentially remove negative logic from an expression.

True

15
New cards

The only way to complement a NOT operator is with another NOT operator.

False