Quiz #8: Looping

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/4

flashcard set

Earn XP

Description and Tags

CS 001: Module 8

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

5 Terms

1
New cards

Three steps must occur in every loop

–Initialize the loop control variable

–Compare the variable to some value

–Alter the variable that controls the loop (T/F)

True

2
New cards

Nested loops maintain two individual loop control variables (T/F)

True

3
New cards

Common mistakes made by programmers

–Neglecting to initialize the loop control variable

–Neglecting to alter the loop control variable

–Using the wrong comparison with the loop control variable

–Including statements inside the loop that belong outside the loop (T/F)

True

4
New cards

A for loop is used when the number of iterations is known. (T/F)

True

5
New cards

In a do-while loop, the loop body executes at least one time because the loop control variable is not tested until after the first iteration. (T/F)

True