Exam 4: Implementing Conditional Logic
Exam 1: Ruby Basics45 Questions
Exam 2: Interacting With Ruby55 Questions
Exam 3: Working With Strings, Objects, and Variables50 Questions
Exam 4: Implementing Conditional Logic49 Questions
Exam 5: Working With Loops50 Questions
Exam 6: Working With Collections of Data46 Questions
Exam 7: Working With Regular Expressions50 Questions
Exam 8: Object-Oriented Programming50 Questions
Exam 9: File and Folder Administration49 Questions
Exam 10: Debugging50 Questions
Exam 11: Ruby on Rails Web Development51 Questions
Select questions type
The unless expression is used to create complex conditional evaluations spread out over multiple lines that perform the opposite type of evaluation as an if expression.
Free
(True/False)
5.0/5
(37)
Correct Answer:
True
Flowcharts provide a visual representation of the overall logic involved in creating some or all of a computer program or script.
Free
(True/False)
4.7/5
(42)
Correct Answer:
True
Unlike if modifiers, if expressions are limited to controlling the execution of a single statement at a time.
Free
(True/False)
4.9/5
(37)
Correct Answer:
False
else is an optional keyword that permits the execution of an alternate set of statements in the event a tested condition evaluates as false.
(True/False)
4.9/5
(40)
You can modify an if modifier to execute one or more statements in the event the test condition evaluates as being false. To accomplish this, you need to add the optional else keyword.
(True/False)
4.9/5
(40)
The case block evaluates an expression that is compared to values associated with one or more when statements.
(True/False)
4.7/5
(30)
The advantages of appending conditional modifiers to the end of script statements include ____.
(Multiple Choice)
4.7/5
(44)
Conditional Logic describes the process of executing sets of code statements based on the whether or not a tested condition proves true.
(True/False)
4.8/5
(36)
A key point to understanding conditional programming logic is that it hinges on whether a condition is evaluated as true or false.
(True/False)
4.8/5
(45)
Ruby supports the use of a number of logical or Boolean operators, including which of the following?
(Multiple Choice)
4.8/5
(35)
What is the difference between the or and the || operators?
(Multiple Choice)
4.7/5
(41)
Which of the following logical (Boolean) operators is most similar to the && operator?
(Multiple Choice)
4.9/5
(47)
The if expression is a conditional evaluation appended to the end of Ruby statements to conditionally control the execution of the statement.
(True/False)
4.8/5
(44)
To determine if one value is greater than or equal to another, which comparison operator should be used?
(Multiple Choice)
4.9/5
(34)
Ruby provides access to a number of conditional expressions, modifiers, and logical operators that can be used to ____.
(Multiple Choice)
4.8/5
(32)
Advantages of the if and unless expressions include all of the following except?
(Multiple Choice)
4.9/5
(29)
The Case statement is a conditional evaluation that performs a series of conditional tests, each of which is compared to a single value.
(True/False)
4.8/5
(39)
The exit method is provided by the kernel class. It forces the immediate termination of a Ruby script.
(True/False)
4.8/5
(31)
What happens if none of the when statements in a case code block match the value of the expression that is evaluated?
(Multiple Choice)
4.8/5
(36)
The case block provides programmers with the ability to ____.
(Multiple Choice)
4.8/5
(36)
Showing 1 - 20 of 49
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)