Chapter 4 COSP 7

7 September 2022
4.7 (114 reviews)
13 test answers

Unlock all answers in this set

Unlock answers (9)
question
C. OR
answer
A(n)________decision is a decision in which at least one of two conditions must be true for an action to take place. a. nested b. NOT c. OR d. AND
question
B. Geroge Boole
answer
Boolean expressions are named after_____________. a. Gerhardt Boolean b. George Boole c. Harold Boolean d. Henry Boole
question
B. first ask the question that is more likely to be false.
answer
For maximum efficiency, a good rule of thumb in an AND decision is to____________.
question
C. first ask the question that is more likely to be true
answer
For maximum efficiency, a good rule of thumb in an OR decision is to____________.
question
c. false OR false
answer
In a truth table, the expression ________ is false. a. true OR true b. true OR false c. false OR false d. false OR true
question
c. case structure
answer
most languages allow you to use a variation of the decision structure called the ________ structure when you must nest a series of decisions about a single variable. a. blocked b. logical c. case d. AND IF
question
c. >
answer
The ___________ sign means "greater than." a. < b. = c. > d. <=
question
a. &&
answer
The conditional AND operator in Java, C++, and C# is _______. a. && b. ** c. & d. AND
question
a. else
answer
The keyword that is NOT included in a single-alternative selection is _________. a. else b. if c. endif d. then
question
b. string
answer
Usually, __________ variables are not considered to be equal unless they are identical. a. character b. string c. integer d. floating point
question
C. compound condition.
answer
when you ask multiple questions before an outcome is determined, you create a _________ condition. a. nested b. dual-alternative c. compound d. single-alternative
question
b. range check
answer
you can perform a ________ by making comparisons using either the lowest or highest value in a range of values. a. logic check b. range check c. trivial expression d. nested if
question
c. NOT
answer
you use the logical _________ operator to reverse the meaning of a Boolean expression. a. OR b. XOR c. NOT d. AND