Verityprep
Question Bank · Unit 4

AP® Computer Science Principles Algorithms and Programming Practice Questions

Work through AP Computer Science Principles practice questions on Algorithms and Programming, 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 81–90 of 100
  1. 81
  2. 82
  3. 83
  4. 84
  5. 85
  6. 86
  7. 87
  8. 88
  9. 89
  10. 90

Question 81

Multiple choice Algorithms
characterList stores single-character strings. Uppercase letters occupy indices 65 through 90. concat(string1,string2) joins two strings; for example…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 82

Multiple choice Algorithms
list1 and list2 are nonempty lists sorted least to greatest. Both algorithms intend to combine all their elements into a sorted newList. Which statement is…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 83

Multiple choice Unit 4: Algorithms and Programming
A teacher uses the table below to assign letter grades based on a numerical score. Numerical Score 90–100 80–89 70–79 60–69 0–59 Letter Grade A B C D F The…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 84

Multiple choice Algorithms
The program should put originalList in random order into initially empty resultList, leaving originalList empty. Which replacement works?…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 85

Multiple choice Algorithms
wordList is a nonempty list of strings. What happens when targetWord does not occur in it? PROCEDURE…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 86

Multiple choice Algorithms
Which task is most likely…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 87

Multiple choice Algorithms
Two identical processors run independent jobs. Each processor can run one job at a time, and a job cannot be split…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 88

Multiple choice Algorithms
Choose two of 28 students so every pair is equally likely. Initially assign unique labels 1–28. Generate j uniformly from 1–28 and have student j…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 89

Multiple choice Algorithms
A programmer completes the user manual for a video game she has developed and realizes she has reversed the roles of goats and sheep throughout the text.…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 90

Multiple choice Logic Gates
⚠️ The figure below shows a circuit composed of two logic gates. An OR gate receives two inputs: false and A. The output of the OR gate feeds…

Sign up now. It's free!

See the full question with its answer and worked solution.

Question 81 of 100
Page 9 of 10