Exam 5: Looping
Exam 1: Introduction to Computers and Programming40 Questions
Exam 2: Introduction to C Plus Plus40 Questions
Exam 3: Expressions and Interactivity40 Questions
Exam 4: Making Decisions40 Questions
Exam 5: Looping40 Questions
Exam 6: Functions40 Questions
Exam 7: Introduction to Classes and Objects40 Questions
Exam 8: Arrays40 Questions
Exam 9: Searching, Sorting, Algorithm Analysis40 Questions
Exam 10: Pointers62 Questions
Exam 11: More About Classes and Object-Oriented Programming70 Questions
Exam 12: More on C-Strings and the String Class40 Questions
Exam 13: Advanced File and Io Operations40 Questions
Exam 14: Recursion20 Questions
Exam 15: Polymorphism and Virtual Functions22 Questions
Exam 16: Exceptions, Templates, and the Standard Template Library Stl40 Questions
Exam 17: Linked Lists38 Questions
Exam 18: Stacks and Queues36 Questions
Exam 19: Binary Trees38 Questions
Select questions type
A while loop is somewhat limited, because the counter can only count up, not down.
Free
(True/False)
4.7/5
(29)
Correct Answer:
False
When a loop is nested inside another loop, the outer loop goes through all its iterations for each iteration of the inner loop.
Free
(True/False)
4.7/5
(44)
Correct Answer:
False
If a while loop has no braces around the body of the loop
Free
(Multiple Choice)
4.7/5
(43)
Correct Answer:
C
A while loop may have a semicolon after the test expression and before the body of the loop, but it is not required.
(True/False)
4.8/5
(30)
A(n) ________ is a variable that is regularly incremented or decremented each time a loop iterates.
(Multiple Choice)
4.9/5
(34)
In a for statement, the ________ expression is executed only once.
(Multiple Choice)
4.9/5
(27)
The do-while loop is a(n) ________ loop, whereas the while loop is a(n) ________ loop.
(Multiple Choice)
4.8/5
(39)
To use files in a C++ program you must include the ________ header file.
(Multiple Choice)
4.9/5
(36)
An initialization expression may be omitted from the for loop if no initialization is required.
(True/False)
4.9/5
(35)
When a loop is nested inside another loop, the inner loop goes through all its iterations for each iteration of the outer loop.
(True/False)
5.0/5
(42)
You can nest a for loop inside another for loop, but cannot nest a while loop inside another while loop or a do-while loop inside another do-while loop.
(True/False)
4.9/5
(34)
Before beginning to add value to it, an accumulator should be initialized to 1.
(True/False)
4.9/5
(29)
________ are C++ operators that change their operands by one.
(Multiple Choice)
4.8/5
(32)
To use files in a C++ program you must include the ________ header file.
(Multiple Choice)
4.9/5
(32)
You may define a(n) ________ in the initialization expression of a for loop.
(Multiple Choice)
4.7/5
(29)
The while loop has two important parts: a condition that is tested and a statement or block of statements that is
(Multiple Choice)
4.8/5
(29)
A for statement contains three expressions: initialization, test, and
(Multiple Choice)
4.9/5
(42)
Showing 1 - 20 of 40
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)