CompSci.rocks

while and for Loops

Free AP Computer Science A multiple-choice practice for topics 2.7–2.8, Unit 2 (Selection and Iteration). Answer five random questions, check your work, and see the ideas behind each one.

Unit 2: Selection and Iteration. Topics 2.7–2.8. This set has 55 questions. Each time the page loads you get five of them, chosen at random. Pick an answer, press Check answer, and read the explanation for every choice. Reload the page or use New questions for a fresh five. Not sure about an idea? Each question's table links to the AP CSA study guide.

Topics assessed

  • 2.7 while Loops
  • 2.8 for Loops

Practice questions

Loading questions…