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 2,121–2,130 of 3,140
  1. 2121
  2. 2122
  3. 2123
  4. 2124
  5. 2125
  6. 2126
  7. 2127
  8. 2128
  9. 2129
  10. 2130

Question 2121

Multiple choice Unit 4: Data Collections
Given the following: double[][] something = { {2.5, 6.8, 8.3, 2.3, 0.0}, {6.1, 10.2, 1.3, - 2.5, - 9.9}, {1.1, 2.3, 5.8, 13.21, 34.55} }; We want to replace the…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 2122

Multiple choice Unit 4: Data Collections
Given the following: String[][] poem = { {"I", "am", "the", "cookie", "monster."}, {"Would", "you", "like", "a", "cookie?"}, {"COOOOKIE", "OM", "NOM", "NOM",…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 2123

Multiple choice Unit 4: Data Collections
Consider the following code segment, which is intended to create and initialize the 2D array words where the length of each word corresponds to the product of…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 2124

Multiple choice Unit 4: Data Collections
Consider the following code segment, which is intended to display the word boards. String[][] twoLetters = {{"ab", "ac", "ad", "ar", "af"}, {"bo", "be", "bi",…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 2125

Multiple choice Unit 4: Data Collections
Consider the following code segment: int[][] nums = new int[5][5]; for (int i = 0;i< nums.length;i++) { for (int j =…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 2126

Multiple choice Unit 4: Data Collections
Consider the following code segment: String[][] word = {{"DOE", "A", "DEER"}, {"A", "FEMALE", "DEER"}, {"RAY", "A", "DROP"}, {"OF", "GOLDEN", "SUN"}}; int…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 2127

Multiple choice Unit 4: Data Collections
Consider the following code segment: int[][] arr = {{10, 9, 8}, {7, 6, 5}, {4, 3, 2}}; for (int row = 0;row < arr.length;row++) { for (int…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 2128

Multiple choice Unit 4: Data Collections
Consider the following method, sumTo10, that traverses a 2D array checking to see if the sum of all integers in each array are equal to 10. The method will…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 2129

Multiple choice Unit 4: Data Collections
Which of the following traversals would print all of the…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 2130

Multiple choice Unit 4: Data Collections
Which of the following traversals would print all of the…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 2,121 of 3,140
Page 213 of 314