Verityprep
Question Bank

AP® Computer Science A Multiple Choice Questions

Work through AP Computer Science A multiple-choice 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 341–350 of 2,811
  1. 341
  2. 342
  3. 343
  4. 344
  5. 345
  6. 346
  7. 347
  8. 348
  9. 349
  10. 350

Question 341

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 342

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 343

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 344

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 345

Multiple choice Unit 1: Using Objects and Methods
Consider the following method: public static int f(int a, int b, int c) {…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 346

Multiple choice Unit 1: Using Objects and Methods
Given String s = "abcdefgh", what is the value of…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 347

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

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 348

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

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 349

Multiple choice Unit 1: Using Objects and Methods
Which of the following correctly extracts the last three…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 350

Multiple choice Unit 1: Using Objects and Methods
A method repeat is defined as: public static String repeat(String s, int n) { String r = "";…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 341 of 2,811
Page 35 of 282