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 871–880 of 3,140
  1. 871
  2. 872
  3. 873
  4. 874
  5. 875
  6. 876
  7. 877
  8. 878
  9. 879
  10. 880

Question 871

Multiple choice Unit 2: Selection and Iteration
Which…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 872

Multiple choice Unit 2: Selection and Iteration
What will this code output? if (true && true && false) { System.out.println("Hello…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 873

Multiple choice Unit 2: Selection and Iteration
What will this program print if the value of grade is 80? if(grade > 90) { System.out.println("A");…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 874

Multiple choice Unit 2: Selection and Iteration
What will the values of x and y be after this code segment runs? int x = 100; int y =…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 875

Multiple choice Unit 2: Selection and Iteration
Assuming a and b are properly initialized boolean values,…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 876

Multiple choice Unit 2: Selection and Iteration
A student is trying to determine if the following two expressions are equivalent. A. x && (!x ||…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 877

Multiple choice Unit 2: Selection and Iteration
Given a, b, and c are properly initialized boolean values, what values…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 878

Multiple choice Unit 2: Selection and Iteration
In order to ride the zip line, you need to be at least 12 years old and weigh at least 75 pounds, but no more than 300 pounds. Which of the following code…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 879

Multiple choice Unit 2: Selection and Iteration
Given the following: if (x > y) { y *= 2; } else if (y > x) { x *= 2; } if (x > y) { y *= 2; } if (y…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 880

Multiple choice Unit 2: Selection and Iteration
Assuming weekday and holiday are properly initialized booleans, which…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 871 of 3,140
Page 88 of 314