Loops Quiz

Quiz
•
Computers
•
11th Grade
•
Hard
Garrett Baltzer
FREE Resource
22 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
A while loop has the following format:
while (condition)
{
...
}
while
{
...
}
continue while (condition)
{
...
}
while [condition]
[
...;
]
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
A while loop carries on as long as...
The condition in the brackets is true
The condition in the brackets is false
i < 10
the for loop has not ended
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
OUTPUT?
int i = 1;
while (i < 5) {
System.out.println("Hello");
i++;
}
Hello
Hello
Hello
Hello
Hello
Hello
Hello
Hello
Hello
Hello
Hello
Hello
Hello
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How many stars are printed?
7
3
4
5
Infinite Loop
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
In total, how many times is the inner loop executed?
5
10
15
50
Infinite Loop
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the following code print?
A rectangle of 9 rows with 5 stars per row
A rectangle of 6 rows with 6 stars per row
A rectangle of 7 rows with 5 stars per row
A rectangle of 7 rows with 6 stars per row
Infinite Loop
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
If a loop condition is never satisfied then the loop does not execute.
Create a free account and access millions of resources
Similar Resources on Wayground
20 questions
Computer 10 | Introduction to Java

Quiz
•
9th - 12th Grade
25 questions
Algorithms - python (GCSE)

Quiz
•
10th - 12th Grade
27 questions
Intro to Microbit

Quiz
•
9th - 12th Grade
21 questions
Python Strings

Quiz
•
11th Grade
18 questions
Kiểu dữ liệu xâu kí tự trong Python

Quiz
•
10th Grade - University
20 questions
Variables and Loops Review

Quiz
•
9th - 12th Grade
20 questions
Programming

Quiz
•
9th - 11th Grade
20 questions
Java For Loop basic syntax

Quiz
•
9th - 12th Grade
Popular Resources on Wayground
10 questions
Video Games

Quiz
•
6th - 12th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
10 questions
UPDATED FOREST Kindness 9-22

Lesson
•
9th - 12th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
20 questions
US Constitution Quiz

Quiz
•
11th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade