for and while loops level 2
Quiz
•
Computers
•
9th - 12th Grade
•
Medium
Brian Miller
Used 6+ times
FREE Resource
Enhance your content in a minute
12 questions
Show all answers
1.
FILL IN THE BLANK QUESTION
1 min • 1 pt
The x variable in the FOR LOOP starts at what value
2.
FILL IN THE BLANK QUESTION
1 min • 1 pt
The x variable in the FOR LOOP ends at what value?
3.
FILL IN THE BLANK QUESTION
1 min • 1 pt
The x variable in the FOR LOOP increments by how much after each iteration of the loop?
4.
FILL IN THE BLANK QUESTION
1 min • 1 pt
The variable s is initialized before the FOR LOOP starts. What value is the starting value for s?
5.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
The variable s is initialized before the FOR LOOP starts and is incremented in the loop. What LINE in the given code INITIALIZES s?
int s = 0;
for(int x=0; x<=30; x=x+10){
s=s+x;
System.out.println(x+" "+s);
6.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
The variable s is initialized before the FOR LOOP starts and is incremented in the loop. What LINE in the given code INCREMENTS s?
int s= 0;
for(int x=0; x<=30; x=x+10){
s=s+x;
System.out.println(x+" "+s);
7.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the FIRST line of the output produced by this code?
0 10
0 0
x s
10 30
Create a free account and access millions of resources
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
10 questions
NHTW Programming
Quiz
•
9th Grade
15 questions
TEST DE PENSAMIENTO LOGICO
Quiz
•
10th Grade
12 questions
Основы алгебры логики
Quiz
•
10th Grade
10 questions
Activity 1: How well do you know Java?
Quiz
•
9th Grade
15 questions
4.6.4 Logic Gates
Quiz
•
10th Grade - Professi...
12 questions
Wee Word Intro
Quiz
•
7th - 12th Grade
15 questions
информатика
Quiz
•
10th Grade
10 questions
Hour of Code
Quiz
•
2nd - 12th Grade
Popular Resources on Wayground
5 questions
This is not a...winter edition (Drawing game)
Quiz
•
1st - 5th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
10 questions
Identify Iconic Christmas Movie Scenes
Interactive video
•
6th - 10th Grade
20 questions
Christmas Trivia
Quiz
•
6th - 8th Grade
18 questions
Kids Christmas Trivia
Quiz
•
KG - 5th Grade
11 questions
How well do you know your Christmas Characters?
Lesson
•
3rd Grade
14 questions
Christmas Trivia
Quiz
•
5th Grade
20 questions
How the Grinch Stole Christmas
Quiz
•
5th Grade
