Deck 3: Making Decisions

ملء الشاشة (f)
exit full mode
سؤال
The selection structure can be called an if-then structure.
استخدم زر المسافة أو
up arrow
down arrow
لقلب البطاقة.
سؤال
All modern programming languages support ____ types of relational comparison operators.

A)two
C)four
B)three
D)six
سؤال
In pseudocode, a(n) ____ statement is used to clearly show where the selection structure ends.

A)end
C)endifelse
B)endif
D)stop
سؤال
You can ask every programming question by using one of only four types of comparison operators in a Boolean expression.
سؤال
Besides being awkward to use, the "____" comparison operator is the one most likely to be different in various programming languages.

A)equal to
C)not equal to
B)greater than
D)less than
سؤال
A(n) ____ expression is one that represents only one of two states, usually expressed as true or false.

A)alternative
C)Boolean
B)dual
D)double
سؤال
When you combine AND and OR operators within the same statement, the AND operators take precedence.
سؤال
You use the ____ operator to reverse the meaning of a Boolean expression.

A)duplicate
C)logical NOT
B)reverse
D)unequal
سؤال
For greatest program efficiency when using the OR operator, first ask the question that is more likely to be true.
سؤال
In a flowchart or in pseudocode, you can use the symbol that mathematicians use to mean "not equal," which is ____.

A)an equal sign with an octagon over it
C)an equal sign with a slash after it
B)an equal sign with a circle around it
D)an equal sign with a slash through it
سؤال
Computer circuitry consists of two-state on/off switches, often represented by 1 or 0.
سؤال
Most programming languages support a NOT operator, which reverses the meaning of a Boolean expression.
سؤال
A structure that includes separate actions when an expression is true and when it is false is called a(n) ____ structure.

A)dual-alternative selection
C)single-alternative selection
B)diverging selection
D)null-alternative selection
سؤال
An AND decision can be constructed using a ____ decision.

A)nested
C)combined
B)stacked
D)dual
سؤال
Usually, a comparison operator is used to compare values of different data types.
سؤال
Only a few decisions you make in a computer program involve evaluating a Boolean expression.
سؤال
When using the OR operator, an action is taken when at least one of the comparisons evaluates to true.
سؤال
The structure that takes one of two paths based on a decision is called a(n) ____ structure.

A)if-then
C)if-then-else
B)if-else
D)if-endif
سؤال
Most programming languages allow you to express "greater than or equal to" by typing ____.

A)>=
C)==<
B)<=
D)==>
سؤال
For greatest program efficiency when using the AND operator, first ask the question that is more likely to be true.
سؤال
The ____________________ operator evaluates to true when its operands are considered to have the same value.
سؤال
In a(n) ____________________ selection, action is required for only one outcome of a question.
سؤال
A common error when using range checking is creating a(n) ____ path in the code.

A)unreachable
C)parallel
B)ending
D)decision
سؤال
A structured selection must have one entry point at the decision, and ____ exit point(s) when the two logical paths rejoin.

A)one
C)three
B)two
D)four
سؤال
What is one common error in using an OR selection?

A)using AND logic when OR is needed
C)using too many comparison operators
B)creating structured logic
D)using too few comparison operators
سؤال
When structures are "on top of" each other, they are known as ____________________ structures.
سؤال
A(n) ____ decision is used when either one of two conditions must be met.

A)case
C)AND
B)if
D)OR
سؤال
You can use ____ statements instead of using AND and OR operators.

A)conditional
C)nesting loop
B)stacked if
D)nesting if
سؤال
Which takes precedence when the two are combined in a single statement: AND or OR?

A)OR
C)whichever comes first
B)AND
D)whichever comes last
سؤال
When you need to ask multiple questions before an outcome is determined, you must create a ____.

A)dual condition
C)large condition
B)compound condition
D)coordinated condition
سؤال
You should never ask a question if there is ____ possible answer(s) or outcome(s).

A)an unknown set of
C)two or fewer
B)a known set of
D)only one
سؤال
When you use one or more ____ operators to combine two or more Boolean expressions, each Boolean expression must be true for the entire expression to be evaluated as true.

A)AND
C)NOT
B)OR
D)EQUALS
سؤال
Many programming languages allow you to use ____ to force an expression to evaluate first.

A)a pound sign
C)parentheses
B)an asterisk
D)quotation marks
سؤال
____ are diagrams used in mathematics and logic to help describe the truth of an entire expression based on the truth of its parts.

A)Text tables
C)Results tables
B)Truth tables
D)Yes/No tables
سؤال
In an AND decision, why is it good practice to make the first question the one that is less likely to be true?

A)This eliminates all instances of the second decision.
B)This eliminates as many instances of the second decision as possible.
C)This eliminates evaluation of the first decision.
D)This makes program execution longer.
سؤال
A(n) ____ of values is any series of contiguous values that fall between specified limits.

A)group
C)range
B)assortment
D)set
سؤال
A dual-alternative selection is also known as a(n) ____________________ structure.
سؤال
The value of a(n) ____________________ expression can only be true or false.
سؤال
In pseudocode, the if, else, and endif statements should align ____.

A)diagonally
C)vertically
B)on the same horizontal line
D)horizontally
سؤال
A series of nested if statements can also be called a ____ if statement.

A)layered
C)stacked
B)cascading
D)dual
سؤال
In a(n) ____________________ decision, more than one condition must be true for an action to take place.
سؤال
An AND decision can be constructed using a nested ____________________.
سؤال
When you use a(n) ____________________ operator, only one of the conditions in an expression must be true for the resulting action to take place.
سؤال
You might say that a path that can never be traveled in a program is a(n) ____________________ path.
سؤال
____________________ are diagrams used in mathematics and logic to help describe the truth of an entire expression.
سؤال
In a(n) ____________________ condition, you ask multiple questions before an outcome is determined.
سؤال
To perform a(n) ____________________, make comparisons using either the lowest or highest value in each range of values.
سؤال
An expression in which two constants are compared is called a(n) ____________________ expression.
سؤال
In _______________ evaluation, the computer always skips the second comparison when using an AND operator if the first comparison is false.
سؤال
The order in which operators are evaluated in an expression is determined by ____________________.
فتح الحزمة
قم بالتسجيل لفتح البطاقات في هذه المجموعة!
Unlock Deck
Unlock Deck
1/50
auto play flashcards
العب
simple tutorial
ملء الشاشة (f)
exit full mode
Deck 3: Making Decisions
1
The selection structure can be called an if-then structure.
False
2
All modern programming languages support ____ types of relational comparison operators.

A)two
C)four
B)three
D)six
D
3
In pseudocode, a(n) ____ statement is used to clearly show where the selection structure ends.

A)end
C)endifelse
B)endif
D)stop
B
4
You can ask every programming question by using one of only four types of comparison operators in a Boolean expression.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
5
Besides being awkward to use, the "____" comparison operator is the one most likely to be different in various programming languages.

A)equal to
C)not equal to
B)greater than
D)less than
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
6
A(n) ____ expression is one that represents only one of two states, usually expressed as true or false.

A)alternative
C)Boolean
B)dual
D)double
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
7
When you combine AND and OR operators within the same statement, the AND operators take precedence.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
8
You use the ____ operator to reverse the meaning of a Boolean expression.

A)duplicate
C)logical NOT
B)reverse
D)unequal
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
9
For greatest program efficiency when using the OR operator, first ask the question that is more likely to be true.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
10
In a flowchart or in pseudocode, you can use the symbol that mathematicians use to mean "not equal," which is ____.

A)an equal sign with an octagon over it
C)an equal sign with a slash after it
B)an equal sign with a circle around it
D)an equal sign with a slash through it
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
11
Computer circuitry consists of two-state on/off switches, often represented by 1 or 0.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
12
Most programming languages support a NOT operator, which reverses the meaning of a Boolean expression.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
13
A structure that includes separate actions when an expression is true and when it is false is called a(n) ____ structure.

A)dual-alternative selection
C)single-alternative selection
B)diverging selection
D)null-alternative selection
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
14
An AND decision can be constructed using a ____ decision.

A)nested
C)combined
B)stacked
D)dual
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
15
Usually, a comparison operator is used to compare values of different data types.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
16
Only a few decisions you make in a computer program involve evaluating a Boolean expression.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
17
When using the OR operator, an action is taken when at least one of the comparisons evaluates to true.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
18
The structure that takes one of two paths based on a decision is called a(n) ____ structure.

A)if-then
C)if-then-else
B)if-else
D)if-endif
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
19
Most programming languages allow you to express "greater than or equal to" by typing ____.

A)>=
C)==<
B)<=
D)==>
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
20
For greatest program efficiency when using the AND operator, first ask the question that is more likely to be true.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
21
The ____________________ operator evaluates to true when its operands are considered to have the same value.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
22
In a(n) ____________________ selection, action is required for only one outcome of a question.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
23
A common error when using range checking is creating a(n) ____ path in the code.

A)unreachable
C)parallel
B)ending
D)decision
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
24
A structured selection must have one entry point at the decision, and ____ exit point(s) when the two logical paths rejoin.

A)one
C)three
B)two
D)four
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
25
What is one common error in using an OR selection?

A)using AND logic when OR is needed
C)using too many comparison operators
B)creating structured logic
D)using too few comparison operators
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
26
When structures are "on top of" each other, they are known as ____________________ structures.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
27
A(n) ____ decision is used when either one of two conditions must be met.

A)case
C)AND
B)if
D)OR
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
28
You can use ____ statements instead of using AND and OR operators.

A)conditional
C)nesting loop
B)stacked if
D)nesting if
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
29
Which takes precedence when the two are combined in a single statement: AND or OR?

A)OR
C)whichever comes first
B)AND
D)whichever comes last
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
30
When you need to ask multiple questions before an outcome is determined, you must create a ____.

A)dual condition
C)large condition
B)compound condition
D)coordinated condition
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
31
You should never ask a question if there is ____ possible answer(s) or outcome(s).

A)an unknown set of
C)two or fewer
B)a known set of
D)only one
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
32
When you use one or more ____ operators to combine two or more Boolean expressions, each Boolean expression must be true for the entire expression to be evaluated as true.

A)AND
C)NOT
B)OR
D)EQUALS
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
33
Many programming languages allow you to use ____ to force an expression to evaluate first.

A)a pound sign
C)parentheses
B)an asterisk
D)quotation marks
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
34
____ are diagrams used in mathematics and logic to help describe the truth of an entire expression based on the truth of its parts.

A)Text tables
C)Results tables
B)Truth tables
D)Yes/No tables
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
35
In an AND decision, why is it good practice to make the first question the one that is less likely to be true?

A)This eliminates all instances of the second decision.
B)This eliminates as many instances of the second decision as possible.
C)This eliminates evaluation of the first decision.
D)This makes program execution longer.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
36
A(n) ____ of values is any series of contiguous values that fall between specified limits.

A)group
C)range
B)assortment
D)set
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
37
A dual-alternative selection is also known as a(n) ____________________ structure.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
38
The value of a(n) ____________________ expression can only be true or false.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
39
In pseudocode, the if, else, and endif statements should align ____.

A)diagonally
C)vertically
B)on the same horizontal line
D)horizontally
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
40
A series of nested if statements can also be called a ____ if statement.

A)layered
C)stacked
B)cascading
D)dual
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
41
In a(n) ____________________ decision, more than one condition must be true for an action to take place.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
42
An AND decision can be constructed using a nested ____________________.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
43
When you use a(n) ____________________ operator, only one of the conditions in an expression must be true for the resulting action to take place.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
44
You might say that a path that can never be traveled in a program is a(n) ____________________ path.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
45
____________________ are diagrams used in mathematics and logic to help describe the truth of an entire expression.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
46
In a(n) ____________________ condition, you ask multiple questions before an outcome is determined.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
47
To perform a(n) ____________________, make comparisons using either the lowest or highest value in each range of values.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
48
An expression in which two constants are compared is called a(n) ____________________ expression.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
49
In _______________ evaluation, the computer always skips the second comparison when using an AND operator if the first comparison is false.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
50
The order in which operators are evaluated in an expression is determined by ____________________.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.
فتح الحزمة
k this deck
locked card icon
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 50 في هذه المجموعة.