Search the complete library

What do you want to learn or calculate?

Quick linksAll calculatorsMath subjectsPractice questionsFormula library
← AP Computer Science Principles Not started
Simulate the decision-making

Prepare for the timed AP Computer Science Principles test.

Your answers are held until submission. The final review identifies the units that need another pass.

AP Computer Science Principles coverage and review map

Connect every question to the exact skill it rehearses. Work through the units in order, then return to any topic that still needs a hint or a second attempt.

01

Creative Development

Program purpose, collaboration, iterative design

Goal: recognise a creative development problem from its wording, carry out the governing method, and check that the result is reasonable.

02

Data

Binary, compression, abstraction, data analysis

Goal: recognise a data problem from its wording, carry out the governing method, and check that the result is reasonable.

03

Algorithms and Programming

Variables, lists, procedures, algorithms, simulation

Goal: recognise a algorithms and programming problem from its wording, carry out the governing method, and check that the result is reasonable.

04

Computer Systems and Networks

Internet protocols, fault tolerance, parallel computing

Goal: recognise a computer systems and networks problem from its wording, carry out the governing method, and check that the result is reasonable.

05

Impact of Computing

Bias, privacy, security, digital divide

Goal: recognise a impact of computing problem from its wording, carry out the governing method, and check that the result is reasonable.

AP Computer Science Principles questions with worked answers

These 8 questions are printed in full on this page and are drawn across all 5 course units. Nothing here is generated on the fly. Cover the options, solve each one on paper, and only then open the worked answer to compare your method with the one shown.

Question 1: How many different values can be represented with 6 bits?

AP Computer Science Principles · Data

  1. 64
  2. 36
  3. 12
  4. 32
Show the worked answer
  1. Each bit is either 0 or 1, so every extra bit doubles the count.
  2. With n bits there are 2^n possible values.
  3. 2^6 = 2 x 2 x 2 x 2 x 2 x 2.
  4. That equals 64 values, from 0 through 63.

Answer: 64

Question 2: A 2,000 KB image is compressed to 400 KB. What percent of the original size was removed?

AP Computer Science Principles · Data

  1. 80%
  2. 20%
  3. 40%
  4. 5%
Show the worked answer
  1. The amount removed is 2,000 - 400 = 1,600 KB.
  2. Compare that with the original size.
  3. 1,600 / 2,000 = 0.8.
  4. So 80% was removed and 20% remains.

Answer: 80%

Question 3: Binary search runs on a sorted list of 1,000 items. What is the largest number of comparisons it may need?

AP Computer Science Principles · Algorithms and Programming

  1. 10
  2. 500
  3. 1,000
  4. 100
Show the worked answer
  1. Binary search cuts the remaining list in half after each comparison.
  2. After k comparisons at most 2^k items can be distinguished.
  3. 2^9 = 512, which is not enough, and 2^10 = 1,024, which is.
  4. So at most 10 comparisons are needed.

Answer: 10

Question 4: A loop that runs n times contains another loop that also runs n times. How does the running time grow?

AP Computer Science Principles · Algorithms and Programming

  1. In proportion to n squared
  2. In proportion to n
  3. In proportion to 2 to the power n
  4. It does not depend on n
Show the worked answer
  1. The inner loop finishes n steps for every single pass of the outer loop.
  2. The outer loop makes n passes.
  3. Total steps are n x n.
  4. That is n squared, so doubling n makes the program take about four times as long.

Answer: In proportion to n squared

Question 5: IPv4 addresses use 32 bits. About how many distinct addresses is that?

AP Computer Science Principles · Computer Systems and Networks

  1. About 4.3 billion
  2. About 4.3 million
  3. About 32 billion
  4. About 65,536
Show the worked answer
  1. The number of addresses is 2 raised to the number of bits.
  2. 2^32 = 4,294,967,296.
  3. That is about 4.3 billion.
  4. It is not enough for today's devices, which is why IPv6 uses 128 bits.

Answer: About 4.3 billion

Question 6: Why does splitting a message into packets that travel by different routes make the Internet more reliable?

AP Computer Science Principles · Computer Systems and Networks

  1. If one path fails, packets can still reach the destination another way.
  2. Packets travel faster than a whole message would.
  3. Packets do not need to be reassembled at the destination.
  4. Each packet is automatically encrypted by the router.
Show the worked answer
  1. Routing is decided hop by hop, not fixed in advance.
  2. Because there are many possible paths, a broken link is not fatal.
  3. This redundancy is what makes the network fault tolerant.
  4. Speed and encryption are separate issues, and packets do have to be reassembled in order at the end.

Answer: If one path fails, packets can still reach the destination another way.

Question 7: A facial recognition tool works less accurately for some skin tones because of its training data. What issue is this?

AP Computer Science Principles · Impact of Computing

  1. Algorithmic bias inherited from the data
  2. A hardware failure in the camera
  3. A network latency problem
  4. A data compression error
Show the worked answer
  1. The program learns patterns from the examples it is given.
  2. If some groups appear rarely in the training set, the model has less to learn from about them.
  3. The resulting uneven accuracy is called algorithmic bias.
  4. Fixing it means changing the data and the testing, not the camera or the network.

Answer: Algorithmic bias inherited from the data

Question 8: A program gives a wrong result for one specific input but runs without crashing. What kind of error is this?

AP Computer Science Principles · Creative Development

  1. A logic error
  2. A syntax error
  3. A runtime error
  4. An overflow error
Show the worked answer
  1. A syntax error stops the program from running at all.
  2. A runtime error stops the program part way through, with a crash or an exception.
  3. Here the program runs to the end and simply produces the wrong answer.
  4. That is a logic error, best found by testing with inputs whose answers you already know.

Answer: A logic error

Which unit each printed question belongs to

Use this map after marking your work. If two misses share a unit, review that unit before starting a generated set.

The 8 printed AP Computer Science Principles questions, the unit each one tests, and its answer.
QuestionUnitWhat it asksAnswer
1DataHow many different values can be represented with 6 bits?64
2DataA 2,000 KB image is compressed to 400 KB. What percent of the original size was removed?80%
3Algorithms and ProgrammingBinary search runs on a sorted list of 1,000 items. What is the largest number of comparisons it may need?10
4Algorithms and ProgrammingA loop that runs n times contains another loop that also runs n times. How does the running time grow?In proportion to n squared
5Computer Systems and NetworksIPv4 addresses use 32 bits. About how many distinct addresses is that?About 4.3 billion
6Computer Systems and NetworksWhy does splitting a message into packets that travel by different routes make the Internet more reliable?If one path fails, packets can still reach the destination another way.
7Impact of ComputingA facial recognition tool works less accurately for some skin tones because of its training data. What issue is this?Algorithmic bias inherited from the data
8Creative DevelopmentA program gives a wrong result for one specific input but runs without crashing. What kind of error is this?A logic error

How the generated AP Computer Science Principles sets are created

The 8 questions above are fixed and checked. The generator at the top of the page is different: it writes fresh questions with AI from the course and unit information shown here, then the application checks each one for a complete prompt, four choices, one keyed answer, and an explanation. Generated questions are original practice—not official or released exam questions—and AI can still make mathematical mistakes. Verify a disputed answer with the stated method, your course materials, or the MathGPT solver, and follow the site's academic-integrity guidance.

Questions about this AP Computer Science Principles course test

What does this page cover?

It covers all 5 AP Computer Science Principles units listed above.

When can I see correct answers and explanations?

Submit the full test first. The result screen then shows every response, the correct answer, and the explanation so you can review each miss.

How long is each section of the AP Computer Science Principles exam?

End-of-course multiple choice: 2 hours, 70 questions. Create Performance Task: Through-course, Program plus written responses.

Which AP Computer Science Principles sections allow a calculator?

Rules change from section to section. End-of-course multiple choice: no calculator. Provided during the exam: Exam Reference Sheet. Create Performance Task: not applicable. Practise each section under its own rule.

Which AP Computer Science Principles units does this test cover?

All five: Creative Development, Data, Algorithms and Programming, Computer Systems and Networks, Impact of Computing. Study first: Create-task evidence capture.

What should I check first when I review a missed AP Computer Science Principles question?

Written responses that describe what the program does instead of how it works. Reference your own code by line and name, and explain the logic.

What should I do with a missed question?

Classify the miss as a definition, setup, calculation, interpretation, or timing error. Re-solve it from a blank page, then use the MathGPT tutor for a hint or method check.