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 421–430 of 3,140
  1. 421
  2. 422
  3. 423
  4. 424
  5. 425
  6. 426
  7. 427
  8. 428
  9. 429
  10. 430

Question 421

Multiple choice Unit 1: Using Objects and Methods
Which of the following calls to Math.random()…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 422

Multiple choice Unit 1: Using Objects and Methods
Consider: String[] parts =…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 423

Multiple choice Unit 1: Using Objects and Methods
Consider the following code segment: String s = "examination"; int result =…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 424

Multiple choice Unit 1: Using Objects and Methods
What is the result of the following…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 425

Multiple choice Unit 1: Using Objects and Methods
Consider the following declaration: String s =…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 426

Multiple choice Unit 1: Using Objects and Methods
Consider the following method: public static String transform(String s) { String result = ""; for (int i = 0; i <…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 427

Multiple choice Unit 1: Using Objects and Methods
A method mystery is defined as follows: public static int mystery(int x, int…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 428

Multiple choice Unit 1: Using Objects and Methods
Which of the following expressions evaluates to true given: String a =…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 429

Multiple choice Unit 1: Using Objects and Methods
Which of the following correctly converts the…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 430

Multiple choice Unit 1: Using Objects and Methods
What is printed by the following? String a = "JAVA";…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 421 of 3,140
Page 43 of 314