If a loop does not have a way of stopping, it is called an infinite loop.
Of the following which one is NOT infinite loop?
whileLoop
Quiz
•
Education
•
9th - 12th Grade
•
Medium
Umit Akdag
Used 5+ times
FREE Resource
5 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
If a loop does not have a way of stopping, it is called an infinite loop.
Of the following which one is NOT infinite loop?
while (number < 5) ;
{ cout << "Hello" ;
number++; }
int number = 0 ;
while (number < 5)
{ cout < "Hello"; }
while (number < 5)
cout < "Hello";
number++;
while (number < 5)
{ cout < "Hello";
number++; }
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the result of this while loop ?
int number = 0;
while (number < 5)
{ cout << "Hello\n";
number++ ; }
Hello
Hello
Hello
Hello
Hello
Hello
Hello
HelloHelloHelloHello
Hello
Hello
Hello
Hello
Hello
Hello
Hello
Hello
Hello
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
While loop will never iterate, if the test expression is false to start with.
T / F ?
TRUE
FALSE
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
in the test expression(condition), any NONZERO value is evaluated as true.
T / F ?
FALSE
TRUE
5.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
The while loop is especially useful for validating input. If an invalid value is entered, a loop can require that the user reenter it as many times as necessary.
Which one is a while Loop for Input Validation?
10 questions
For loop
Quiz
•
8th - 9th Grade
10 questions
Python IF Statements
Quiz
•
9th - 12th Grade
10 questions
Java Strings
Quiz
•
1st Grade - Professio...
10 questions
TLE - ICT - Computer Programming Quiz
Quiz
•
9th Grade
10 questions
Python quiz
Quiz
•
KG - Professional Dev...
10 questions
Fingerprint Classification Practice
Quiz
•
9th - 12th Grade
10 questions
Classify or Explain? A Quiz on Text Types”
Quiz
•
5th Grade - University
10 questions
SOAL 1 SPE
Quiz
•
11th Grade
15 questions
Multiplication Facts
Quiz
•
4th Grade
20 questions
Math Review - Grade 6
Quiz
•
6th Grade
20 questions
math review
Quiz
•
4th Grade
5 questions
capitalization in sentences
Quiz
•
5th - 8th Grade
10 questions
Juneteenth History and Significance
Interactive video
•
5th - 8th Grade
15 questions
Adding and Subtracting Fractions
Quiz
•
5th Grade
10 questions
R2H Day One Internship Expectation Review Guidelines
Quiz
•
Professional Development
12 questions
Dividing Fractions
Quiz
•
6th Grade
25 questions
Spanish preterite verbs (irregular/changed)
Quiz
•
9th - 10th Grade
10 questions
Identify Slope and y-intercept (from equation)
Quiz
•
8th - 9th Grade
10 questions
Juneteenth: History and Significance
Interactive video
•
7th - 12th Grade
8 questions
"Keeping the City of Venice Afloat" - STAAR Bootcamp, Day 1
Quiz
•
9th - 12th Grade
26 questions
June 19th
Quiz
•
4th - 9th Grade
20 questions
Distance, Midpoint, and Slope
Quiz
•
10th Grade
20 questions
Figurative Language Review
Quiz
•
10th Grade
27 questions
STAAR English 1 Review
Quiz
•
9th Grade