Exam 4: Selection Structures

arrow
  • Select Tags
search iconSearch Question
flashcardsStudy Flashcards
  • Select Tags

A(n) ____ is any combination of operands and operators that yields a result.

(Multiple Choice)
4.9/5
(34)

Applying a postfix or prefix ++ operator to a variable of type bool sets the Boolean value to ____.

(Multiple Choice)
4.8/5
(44)

When writing a switch statement, you can use multiple ____ values to refer to the same set of statements.

(Multiple Choice)
4.7/5
(41)

The ____ statement in C++ is used to implement a decision structure in its simplest form choosing between two alternatives.

(Multiple Choice)
4.8/5
(39)

The most commonly used ____ in if statements are simple relational expressions.

(Multiple Choice)
4.8/5
(40)

In C++, relational operators can be used with integer, float, double, and ____________________ operands.

(Short Answer)
4.9/5
(42)

A ____ statement is an alternative to the if-else chain for situations when the condition involves comparing an integer expression to a specific value.

(Multiple Choice)
5.0/5
(36)

A(n) ____ chain is used in programming applications where one set of instructions must be selected from many possible alternatives.

(Multiple Choice)
4.8/5
(35)

Because of the way computers store single-precision and double-precision numbers, you should avoid testing for equality of single-precision and double-precision values and variables by using the relational operator ____________________.

(Short Answer)
4.9/5
(35)

Logical operators AND, OR, and NOT are represented by the symbols , ____, and !, respectively.

(Multiple Choice)
4.9/5
(36)

A ____ statement is a sequence of single statements contained between braces.

(Multiple Choice)
4.7/5
(39)

In C++, the postfix and prefix -- operators can be applied to Boolean variables.

(True/False)
4.9/5
(36)

In the ASCII character set, lowercase letters are considered ____________________ than uppercase letters.

(Short Answer)
4.9/5
(37)

The technique of ____________________ programming includes code to check for improper input data.

(Short Answer)
5.0/5
(34)

The switch statement requires you to list the case values in increasing order.

(True/False)
4.7/5
(40)

A common problem with the if-else statement is using the assignment operator, = , in place of the relational operator == .

(True/False)
5.0/5
(35)

A useful modification of the if-else statement involves omitting the ____ part of the statement.

(Multiple Choice)
4.9/5
(27)

In the switch statement, the ____ keyword identifies values that are compared with the switch expression s value.

(Multiple Choice)
4.8/5
(29)

A switch statement can contain any number of case labels in any order.

(True/False)
4.8/5
(39)

In C++, Boolean variables are declared with the ____ keyword.

(Multiple Choice)
4.9/5
(33)
Showing 21 - 40 of 51
close modal

Filters

  • Essay(0)
  • Multiple Choice(0)
  • Short Answer(0)
  • True False(0)
  • Matching(0)