Exam 4: Selection Structures

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

In C++, the logical ____ operator is used to change an expression to its opposite state.

Free
(Multiple Choice)
4.8/5
(36)
Correct Answer:
Verified

C

In C++, when comparing character data, the char values are coerced to ____ values automatically for the comparison.

Free
(Multiple Choice)
4.9/5
(35)
Correct Answer:
Verified

D

The relational operator ____ is used to represent the condition less than.

Free
(Multiple Choice)
4.7/5
(42)
Correct Answer:
Verified

B

In C++, strings of characters cannot be compared.

(True/False)
4.8/5
(39)

A ____ relational expression consists of a relational operator that compares two operands.

(Multiple Choice)
4.8/5
(32)

The condition used in an if statement can be any valid C++ expression.

(True/False)
4.8/5
(33)

Using nested if statements without including braces to indicate the structure constitutes a common programming error.

(True/False)
5.0/5
(39)

The area in a program where a variable can be used is formally referred to as the ____ of the variable.

(Multiple Choice)
4.8/5
(41)

When the ____________________ logical operator is used with two simple expressions, the condition is true only if both individual expressions are true by themselves.

(Short Answer)
4.9/5
(40)

The ____________________ keyword is optional in a switch statement.

(Short Answer)
4.8/5
(40)

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

(Short Answer)
4.9/5
(33)

A(n) ____________________ statement is a sequence of single statements between braces.

(Short Answer)
4.8/5
(39)

If ____________________ statements are omitted in a switch statement, all cases following the matching case value, including the default case, are executed.

(Short Answer)
4.9/5
(37)

Including one or more if statements inside an existing if statement is called a(n) ____________________ if statement.

(Short Answer)
4.8/5
(43)

The switch statement requires you to terminate each case with a break statement.

(True/False)
4.8/5
(40)

Like all C++ expressions, relational expressions are evaluated to yield a(n) ____________________ result.

(Short Answer)
4.9/5
(32)

The expression in the switch statement must evaluate to a(n) ____ result or a compilation error results.

(Multiple Choice)
4.9/5
(31)

Including one or more if statements inside an existing if statement is called a ____ if statement.

(Multiple Choice)
4.9/5
(30)

An if-else statement without an else part is called a(n) ____________________ if statement.

(Short Answer)
4.8/5
(32)

Checking user input data for erroneous or unreasonable data is referred to as ____.

(Multiple Choice)
5.0/5
(36)
Showing 1 - 20 of 51
close modal

Filters

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