Exam 6: Looping
Exam 1: Creating Java Programs61 Questions
Exam 2: Using Data67 Questions
Exam 3: Using Methods Classes and Objects66 Questions
Exam 4: More Object Concepts66 Questions
Exam 5: Making Decisions66 Questions
Exam 6: Looping66 Questions
Exam 7: Characters Strings and the Stringbuilder68 Questions
Exam 8: Arrays66 Questions
Exam 9: Advanced Array Concepts66 Questions
Exam 10: Introduction to Inheritance66 Questions
Exam 11: Advanced Inheritance Concepts66 Questions
Exam 12: Exception Handling66 Questions
Exam 13: File Input and Output66 Questions
Exam 14: Introduction to Swing Components66 Questions
Exam 15: Advanced Gui Topics66 Questions
Exam 16: Graphics66 Questions
Select questions type
The order of the conditional expressions in the following is most important within a(n) ____ loop. while(requestedNum > LIMIT || requestedNum
(Multiple Choice)
4.8/5
(45)
Describe a counter-controlled loop. Explain the process of incrementing and decrementing, and explain the best method for executing a loop a specific number of times.
(Essay)
4.9/5
(30)
One execution of any loop is called a(n) ____________________.
(Short Answer)
4.8/5
(36)
Using the information provided above, write the while loop that will correctly follow the execution of the flowchart.

(Essay)
4.9/5
(33)
Write a definite while loop that initializes a loop control variable named decreaseOne to 10 and continues while decreaseOne > 0. Decrement the loop control variable by 1 and include the println output "Keep going" within the loop.
(Essay)
4.8/5
(36)
You can use virtually any number of nested loops; however, at some point, your machine will no longer be able to store all the necessary looping information.
(True/False)
4.9/5
(40)
In the expressions b = 8 and c = --b , what value will be assigned to the variable c ?
(Multiple Choice)
4.8/5
(36)
In a do…while loop, the loop will continue to execute until ____.
(Multiple Choice)
4.9/5
(45)
The process of repeatedly increasing a value by some amount is known as ____.
(Multiple Choice)
4.8/5
(40)
How could you rewrite the following code to have the arithmetic performed only once, even if the loop executes 1,000 times?
while (x
// loop body
(Essay)
4.9/5
(40)
How are indefinite loops used for validating data? Why is a loop structure typically the better choice for validating data than an if statement?
(Essay)
4.9/5
(29)
counterLoop = 1;
while(counterLoop
{
System.out.println("Hello");
counterLoop = counterLoop + 1;
}
What is the problem in the above while loop? How would you correct the problem?
(Essay)
4.7/5
(42)
while(10 > 1)
{
System.out.println("This prints forever.");
}
Identify the problem that exists in the above while loop.
(Essay)
4.7/5
(42)
What are some of the shortcuts Java provides programmers for incrementing and accumulating? Give examples of statements.
(Essay)
4.8/5
(39)
When nesting loops, the variable in the outer loop changes more frequently.
(True/False)
4.8/5
(45)
You can initialize more than one variable in a for loop by placing a(n) ____ between the separate statements.
(Multiple Choice)
4.8/5
(32)
Using the flowchart and code above, describe the execution of the loop. Identify the loop control variable and the value of the variable as the code is executed.

(Essay)
4.8/5
(36)
Showing 41 - 60 of 66
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)