Question bank / Advanced Placement / AP Computer Science Principles AP Computer Science Principles: Big Idea 3: Algorithms and Programming Original, AI-authored English practice with worked guidance. Selected topics only; independent teacher review is pending. This is not a complete syllabus, official past-paper collection or predicted exam score. SubjectScout is not affiliated with or endorsed by College Board. SAT practice is not a full adaptive test; AP practice does not simulate an entire exam.
18 original questions across 5 selected topic areas. No account or payment required to practise.
10 questions in this topic. Exact English revisions checked in an AI-assisted academic review; independent teacher approval is still pending.
All topics Big Idea 1: Creative Development (1) Big Idea 2: Data (2) Big Idea 3: Algorithms and Programming (10) Big Idea 4: Computer Systems and Networks (2) Big Idea 5: Impact of Computing (3) Official AP framework reference (framework only, not a source of copied questions).
Topic All topics Big Idea 1: Creative Development Big Idea 2: Data Big Idea 3: Algorithms and Programming Big Idea 4: Computer Systems and Networks Big Idea 5: Impact of Computing Practice view All questions Unanswered Bookmarked Review mistakes Difficulty All levels Foundation Standard Challenge Search questions
0 of 18 checked · 0 correct · 10 shown
Loading saved progress Question 4 · Big Idea 3: Algorithms and Programming · standard
Use AP CSP pseudocode, where <- denotes assignment. What does this code display?
values <- [3, 8, 5, 10]
total <- 0
FOR EACH value IN values
{
IF(value MOD 2 = 0)
{
total <- total + value
}
}
DISPLAY(total) A. 18B. 26C. 2D. 8Check answer Question 5 · Big Idea 3: Algorithms and Programming · challenge
Use AP CSP pseudocode with one-based list indices and <- for assignment. What is displayed?
items <- [4, 7, 9]
INSERT(items, 2, 6)
REMOVE(items, 3)
DISPLAY(items[3]) A. 6B. 7C. An index errorD. 9Check answer Question 6 · Big Idea 3: Algorithms and Programming · standard
In AP CSP pseudocode, r <- RANDOM(1, 8), followed by IF(r > 5) { DISPLAY("win") }. RANDOM includes both endpoints and makes each integer equally likely. What is the probability of displaying win on one execution? A. 5/8B. 3/8C. 1/2D. 2/7Check answer Question 7 · Big Idea 3: Algorithms and Programming · standard
Several screens in an app compute a delivery charge from distance and parcel mass. The rule changes regularly. Which design best uses procedural abstraction? A. Copy the calculation into every screen and change each copy separately.B. Store only the last charge and reuse it for every parcel.C. Define one charge(distance, mass) procedure and call it with each parcel's inputs.D. Replace both inputs with the same constant for all parcels.Check answer Question 11 · Big Idea 3: Algorithms and Programming · standard
An account may proceed only when neither suspended nor expired is true. Both variables are Boolean. Which AP CSP expression is equivalent to NOT(suspended OR expired) for every combination of inputs? A. (NOT suspended) OR (NOT expired)B. suspended AND expiredC. (NOT suspended) AND (NOT expired)D. NOT(suspended AND expired)Check answer Question 12 · Big Idea 3: Algorithms and Programming · challenge
Use AP CSP pseudocode, with <- for assignment. What is displayed?
PROCEDURE score(n)
{
IF(n < 4)
{
RETURN(n + 2)
}
RETURN(2 * n)
}
a <- score(3)
b <- score(a)
DISPLAY(b - a) A. 5B. 2C. 4D. 10Check answer Question 13 · Big Idea 3: Algorithms and Programming · standard
Binary search is applied to the sorted list [2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24, 26, 28, 30]. Each iteration checks the middle value of the remaining candidate interval and discards that value and the impossible half if it is not the target. How many middle-value checks are needed to find 22? A. 3B. 11C. 15D. 4Check answer Question 14 · Big Idea 3: Algorithms and Programming · foundation
A decision problem is known to be undecidable. A developer correctly solves several particular instances. Which conclusion follows? A. The problem must now be decidable because examples were solved.B. Some instances can be solved, but no algorithm can always terminate with the correct yes-or-no answer for every instance.C. Every instance is impossible to solve by any method.D. More processors necessarily produce an algorithm that solves every instance.Check answer Question 15 · Big Idea 3: Algorithms and Programming · standard
Two algorithms solve the same problem. Their operation counts are exactly n^2 and 2^n for an input of size n. In the AP CSP classification, which statement about growth for large n is correct? A. Both counts are polynomial because both use exponents.B. 2^n is polynomial and n^2 is exponential.C. n^2 is polynomial; 2^n is exponential and eventually exceeds any fixed polynomial bound.D. The algorithm requiring 2^n operations must be undecidable.Check answer Question 18 · Big Idea 3: Algorithms and Programming · foundation
A traffic simulation assumes all drivers instantly obey a new speed limit and omits weather. It predicts fewer collisions. Which interpretation is best supported? A. The prediction proves collisions will fall by exactly the simulated amount.B. The prediction is conditional on the model; testing realistic compliance and weather assumptions can improve its usefulness.C. A simulation cannot provide any useful evidence unless it includes every detail of reality.D. Running the unchanged model more often necessarily removes bias from its assumptions.Check answer All Advanced Placement subjects