AP® Computer Science Principles review sheet from Aim for Five (aimforfive.com/csp/units/1)
Unit 1
10–13% of examCreative Development
Programs are made by people, usually working in teams, to solve a problem or let someone create something. In this unit you'll see how programmers collaborate, how a program's purpose shapes its inputs and outputs, how programs are planned, built and documented, and how to find and fix the errors that always creep in. It's the thinking behind your Create task.
Study this unit
Flashcards (33)Practice questions (53)Computer Science Principles must-know sheetFree-response questions on this unit
Write your own answer, then score it with the rubric or with AI.
- Written Response 1: Program design, function and purposeRecipe scaler: users and design1 point · about 15 minutes
- Written Response 1: Program design, function and purposeBus countdown: input and output1 point · about 15 minutes
- Written Response 1: Program design, function and purposeRecycling game: purpose and function1 point · about 15 minutes
- Written Response 1: Program design, function and purposeClub attendance: testing and revising1 point · about 15 minutes
- Written Response 1: Program design, function and purposeWater tracker: documentation1 point · about 15 minutes
- Written Response 1: Program design, function and purposeClinic reminders: users the design leaves out1 point · about 15 minutes
- Written Response 1: Program design, function and purposeStudy timer: crediting borrowed code1 point · about 15 minutes
- Written Response 1: Program design, function and purposeLost and found: meeting users' needs1 point · about 15 minutes
Big ideas
- Teams with different backgrounds and skills catch problems one person would miss
- A program's purpose is the problem it solves; its function is what it does when it runs
- Programs are built in small steps and tested along the way
- Comments and documentation explain code and give credit to code written by others
- Testing with inputs you choose, and outputs you expect, is how you find errors
Full unit reviews
Longer videos that cover the whole unit. Good for a first pass or a final review.
Topics
Most computing innovations are built by teams, and people with different backgrounds, skills and points of view spot needs and problems that one person would miss. Teams share work through practices like pair programming and online tools, and they ask users for feedback through surveys, interviews and testing.
Key terms
- computing innovation
- collaboration
- diverse perspectives
- pair programming
- user feedback
A few quick questions on this topic, with the answers explained.
Every program is written for a purpose, like solving a problem or letting people express themselves, and knowing that purpose helps you design and test it. A program takes input (from a user, a sensor or another program), runs its code and produces output, and many programs are event-driven: code runs when something happens, like a click or a key press.
Key terms
- purpose
- behavior (function)
- input
- output
- event
- code segment
A few quick questions on this topic, with the answers explained.
Building a program means investigating what users need, then designing, prototyping and testing. Development can be iterative (you go back and refine based on feedback) or incremental (you build and test small pieces, then add them together), and comments and other documentation explain your code and credit any code you used that someone else wrote.
Key terms
- iterative development
- incremental development
- program requirements
- prototype
- program documentation
- comments
A few quick questions on this topic, with the answers explained.
There are four kinds of error to know. A logic error means the program runs but does the wrong thing; a syntax error means the code breaks the language's rules; a run-time error happens while the program is running, like using a list index that doesn't exist; and an overflow error happens when a number is outside the range the available bits can hold. You find errors by testing with inputs you pick (including values at the edges of what's allowed) and comparing the output with what you expected, and by tracing the code by hand, using a debugger or adding extra output statements.
Key terms
- logic error
- syntax error
- run-time error
- overflow error
- test case (input and expected output)
- debugging
A few quick questions on this topic, with the answers explained.