Log in
Sign up for FREE
arrow_back
Library

4 - for & while loops

star
star
star
star
star
Last updated about 4 years ago
13 questions
1
1
1
1
1
1
1
1
1
1
1
1
1
Question 1
1.

for loops are best suited for which of the following purposes?

Question 2
2.

Each time through a loop is called a(n)

Question 3
3.

Which of the following is the right order of the parts of a for loop?

Question 4
4.

Which of the following counts through the numbers 0 to 9 inclusive?

Question 5
5.

Given the line of code:

i=i+1;

What can be said?

Question 6
6.

Which of the following has the same effect as i++ ?

Question 7
7.

Why is it acceptable to use i as a counter variable?

Question 8
8.

while loops are best suited for which of the following purposes?

Question 9
9.

Each time through a while loop is called a(n)

Question 10
10.

Which of the following is the right template for a header line in a while loop?

Question 11
11.

Which of the following is the right template for a header line in a while loop?

Question 12
12.

Which of the following counts through the numbers 0 to 9 inclusive?

Question 13
13.

What is wrong with the following code?

int i=0; while( i<100 ) {
Serial.println(i);
i++;
}
Serial.print("After the loop, i’s valuse is:");
Serial.println(i);