Verityprep
Question Bank

AP® Computer Science A Practice Questions

Work through AP Computer Science A practice questions unit by unit, then check each answer against a worked solution.

Free · no sign-up Open questions need no account. Sign up or log in to open the rest.

Questions 831–840 of 3,140
  1. 831
  2. 832
  3. 833
  4. 834
  5. 835
  6. 836
  7. 837
  8. 838
  9. 839
  10. 840

Question 831

Multiple choice Unit 2: Selection and Iteration
How often is the inner…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 832

Multiple choice Unit 2: Selection and Iteration
Consider the following code snippet. Is count < 5 always true, always false, or sometimes true/sometimes…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 833

Multiple choice Unit 2: Selection and Iteration
Consider the following code snippet. Is count < 5 always true, always false, or sometimes true/sometimes false at point 2? int count = 0; while (count…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 834

Multiple choice Unit 2: Selection and Iteration
How many times does the following loop iterate? // x has been…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 835

Multiple choice Unit 2: Selection and Iteration
How many times does the following loop iterate? // x has been initialized with a…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 836

Multiple choice Unit 2: Selection and Iteration
How many times does the following loop execute? // x has been initialized with a…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 837

Multiple choice Unit 2: Selection and Iteration
What will the call to the method funWithNumbers(314159) print to the screen? public void funWithNumbers(double myDouble) { int myInt =…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 838

Multiple choice Unit 2: Selection and Iteration
Consider the following code segment: int x = 10; int y = 2; int count = 1; while(x > y)…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 839

Multiple choice Unit 2: Selection and Iteration
Consider the following code segment: int p = 5; while(p > 0) { for(int j = p; j < p*2; j++) {…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 840

Multiple choice Unit 2: Selection and Iteration
Consider the following code segment: int counter = 5; int sum = 0; while(counter < 10) { sum+= counter; counter+=2; } Which of the following for loops would…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 831 of 3,140
Page 84 of 314