Javascript For loop and While Loop

Quiz
•
Other, Computers
•
12th Grade
•
Hard

Aref .
Used 171+ times
FREE Resource
5 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
what is a for loop?
loops through a number of block of code one time
loops through a block of code a number of times
loops through a block of code one time
many loops through a block of code a number of times
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The number is 0
The number is 1
The number is 2
The number is 3
The number is 4
which is the correct code?
for (i = 0; i < 5 i++)
FOR (i = 0; i < 5; i++)
for (i = 0; i < 4; i++)
for (i = 0; i < 5; i++)
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
what is a while loop?
loops through a block of code as long as a specified condition is false
loops through a block of code as long as a specified condition is true or false
loops through a block of code as long as a specified condition is true
loops through a number block of code as long as a specified condition is true
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The number is 0
The number is 1
The number is 2
The number is 3
The number is 4
The number is 5
The number is 6
The number is 7
The number is 8
The number is 9
which code is correct?
while (i < 10) {
text += "<br>The number is " + i;
i++;
}
while (i < 9) {
text += "<br>The number is " + i;
i++;
}
while (i < 10) {
text += "<br>The number is " + i;
i++
}
while (i < 10)
text += "<br>The number is " + i;
i++;
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
var i = 0;
(i 10) {
console.log(i);
i++
}
fix the code using while loop and i is bigger then 10
WHILE , <
while , bigger
while , <
while , >
Similar Resources on Wayground
10 questions
Python Loops

Quiz
•
9th - 12th Grade
10 questions
LOOPS IN C++

Quiz
•
10th Grade - University
9 questions
AP CS A Quiz 4 Practice

Quiz
•
9th - 12th Grade
10 questions
Express Course Quiz

Quiz
•
12th Grade
10 questions
Programming with C++

Quiz
•
9th - 12th Grade
10 questions
Unit 1 Post Test: Basic Python

Quiz
•
9th - 12th Grade
8 questions
IDENTIFYING TYPES OF LOOPS

Quiz
•
2nd Grade - University
10 questions
8.2 Arrays Cambridge IGCSE 0478

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

Quiz
•
6th - 12th Grade
20 questions
Brand Labels

Quiz
•
5th - 12th Grade
15 questions
Core 4 of Customer Service - Student Edition

Quiz
•
6th - 8th Grade
15 questions
What is Bullying?- Bullying Lesson Series 6-12

Lesson
•
11th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade