Verityprep
Question Bank · Unit 4

AP® Computer Science A Data Collections Practice Questions

Work through AP Computer Science A practice questions on Data Collections, 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 231–240 of 1,222
  1. 231
  2. 232
  3. 233
  4. 234
  5. 235
  6. 236
  7. 237
  8. 238
  9. 239
  10. 240

Question 231

Multiple choice Sorting And Searching
Using inclusive bounds and floor midpoint, how many midpoint elements are…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 232

Multiple choice Sorting And Searching
Binary search is incorrectly applied to unsorted [1,3,6,9,14,10,21]…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 233

Multiple choice Sorting And Searching
For a sorted array of length at least3, when can a left-to-right linear…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 234

Multiple choice Sorting And Searching
What is the maximum number of midpoint inspections…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 235

Multiple choice Sorting And Searching
Which approach…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 236

Multiple choice Sorting And Searching
Which sorting method is implemented? public int[] array public int[] tempArr public int length public void sort(int[] inputArr) {…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 237

Multiple choice Sorting And Searching
For standard insertion sort and top-down merge sort…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 238

Multiple choice Sorting And Searching
Which…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 239

Multiple choice Recursion
Consider the following recursive function: public int mystery(int n) { if (n == 0) { return 2; } else { return 2 * mystery(n -…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 240

Multiple choice Recursion
Consider the following recursive function: public static void printDigits(int number) { if (number == 0) { return;…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 231 of 1,222
Page 24 of 123