Exam 5: Repetition Structures
Exam 1: Introduction to Computers and Programming35 Questions
Exam 2: Input, Processing, and Output35 Questions
Exam 3: Simple functions34 Questions
Exam 4: Decision Structures and Boolean Logic35 Questions
Exam 5: Repetition Structures35 Questions
Exam 6: Value-Returning functions and Modules35 Questions
Exam 7: files and Exceptions35 Questions
Exam 8: Lists and Tuples35 Questions
Exam 9: More About Strings35 Questions
Exam 10: Dictionaries and Sets35 Questions
Exam 11: Classes and Object-Oriented Programming35 Questions
Exam 12: Inheritance35 Questions
Exam 13: Recursion35 Questions
Exam 14: GUI Programming35 Questions
Select questions type
A(n) _______________ validation loop is sometimes called an error trap or an error handler.
(Short Answer)
4.8/5
(84)
What are the values that the variable num contains through the iterations of the following for loop? for num in range(2, 9, 2)
(Multiple Choice)
4.9/5
(64)
A(n) _______________ total is a sum of numbers that accumulates with each iteration of a loop.
(Short Answer)
4.9/5
(73)
functions can be called from statements in the body of a loop, and loops can be called from the body of a function.
(True/False)
4.9/5
(85)
A better way to repeatedly perform an operation is to write the statements for the task once, and then place the statements in a loop that will repeat the statements as many times as necessary.
(True/False)
4.9/5
(78)
What is the disadvantage of coding in one long sequence structure?
(Multiple Choice)
4.8/5
(81)
The first input operation is called the _____, and its purpose is to get the first input value that will be tested by the validation loop.
(Multiple Choice)
4.8/5
(67)
A(n) _______________ loop usually occurs when the programmer forgets to write code inside the loop that makes the test condition false.
(Short Answer)
4.9/5
(83)
The acronym _______________ refers to the fact that the computer cannot tell the difference between good data and bad data.
(Short Answer)
4.8/5
(75)
The first line in the while loop is referred to as the condition clause.
(True/False)
4.9/5
(90)
What type of loop structure repeats the code based on the value of the Boolean expression?
(Multiple Choice)
5.0/5
(89)
The variable used to keep the running total is called a(n) _____.
(Multiple Choice)
4.9/5
(71)
What is not an example of an augmented assignment operator?
(Multiple Choice)
4.9/5
(93)
_____ is the process of inspecting data that has been input to a program to make sure it is valid before it is used in a computation.
(Multiple Choice)
4.9/5
(75)
Reducing duplication of code is one of the advantages of using a loop structure.
(True/False)
4.7/5
(92)
Showing 21 - 35 of 35
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)