See what your study plan could look like
Based on this guide's real question bank — 155 practice questions across 8 units. Slide to match your situation.
0
Questions you'll complete
0
Units covered
0%
of the full question bank
/
0% of the question bank attempted
Unit 1: Creative Development
▾Collaboration and the development process
Programs are built by people working together through planning, testing and revision.
- Collaboration brings diverse perspectives, skills and feedback, which improves the quality of a program.
- Development processes are often iterative: design, prototype, test, get feedback and revise, repeating the cycle.
- Incremental development builds and tests small pieces one at a time; pair programming has two people share one computer.
- Documenting and commenting code helps others and your future self understand what the program does.
Purpose, requirements and user feedback
Good programs begin with a clear purpose and are tested with real users.
- A program's purpose is the problem it solves or the interest it satisfies; requirements describe what it must do.
- Input comes from users or other programs; output is what the program produces; user interface design shapes how people interact.
- Testing with varied users and inputs finds problems; user feedback guides improvements.
- A computing innovation can have intended and unintended effects, both beneficial and harmful.
Errors and debugging
Programmers expect errors and use strategies to find and fix them.
- Syntax errors break the rules of the language; logic errors make the program run but give wrong results; runtime errors occur while running.
- Overflow errors occur when a value is larger than the computer can store; round-off errors come from limited precision for real numbers.
- Debugging strategies: test with different inputs, hand-trace the code, add display statements, and test small segments in isolation.
A program that runs without crashing can still contain a logic error; testing must check the output, not just that it ran.
Collaboration does not mean everyone writes every line; roles and communication matter.
Unit 2: Data Representation
▾Binary numbers and bits
Computers represent all information using bits, each either 0 or 1.
- A bit is a single binary digit; a byte is 8 bits. With n bits you can represent 2^n different values (n bits count from 0 up to 2^n - 1).
- Binary place values from the right are 1, 2, 4, 8, 16, 32, 64, 128; add the place values that have a 1 to convert to decimal.
- Using more bits lets you represent more values or finer detail; the same bits can represent numbers, text, colors or sound depending on the interpretation.
- Overflow happens when a number exceeds the largest value the bits can hold.
Representing text, images and sound
All kinds of data are encoded as bits using agreed-upon formats.
- Text uses character encodings such as ASCII and Unicode; Unicode represents characters from many languages.
- Images are grids of pixels; each pixel's color is stored as numbers, commonly red, green and blue values (RGB).
- Sound is sampled at regular intervals; a higher sampling rate and more bits per sample give higher quality and larger files.
- Analog data is continuous; digitizing samples it, which may lose some detail.
Compression
Compression reduces the number of bits needed to store or send data.
- Lossless compression allows the original data to be reconstructed exactly (PNG, ZIP, FLAC); lossy compression discards some data for smaller files (JPEG, MP3).
- Lossless is needed when exact data matters (text, programs); lossy is acceptable when small losses are not noticeable.
- Metadata is data about data, such as the date a photo was taken; it can reveal information you did not intend to share.
The number of values with n bits is 2 to the n, but the largest value is 2^n minus 1 because counting starts at 0.
Lossy compression cannot restore the original data; lossless can.
Unit 3: Data Analysis and Big Data
▾Extracting information from data
Data can be examined for patterns and used to draw conclusions.
- Data is raw facts; information is the useful meaning extracted from data; patterns and trends in data support decisions.
- Correlation does not imply causation: two variables can move together without one causing the other.
- Bias in how data is collected or who is included can lead to misleading conclusions.
- Visualizations such as charts and graphs help people see patterns.
Big data and data sets
Computers can analyze extremely large collections of data.
- Big data sets are too large for traditional tools; they are processed using parallel and distributed computing.
- Data sets may be incomplete, contain errors or be biased, so data must be cleaned before analysis.
- Scalability describes how well a system handles growth in data or users.
- Using data to make decisions raises privacy concerns about how data is collected, stored and shared.
Processing data with programs
Programs filter, sort and combine data to answer questions.
- Filtering selects the data that meet a condition; sorting arranges data in order; transforming changes data into another form.
- Combining data sets can reveal new information but can also compromise privacy by re-identifying individuals.
- Spreadsheets and databases store and process structured data.
A strong correlation is not proof of cause.
Anonymized data can sometimes be re-identified when combined with other data sets.
Unit 4: Algorithms
▾What an algorithm is
An algorithm is a finite set of instructions that accomplishes a task.
- Every algorithm can be built from three constructs: sequencing (steps in order), selection (choosing with conditions) and iteration (repeating).
- Different algorithms can solve the same problem with different efficiency.
- Algorithms are expressed in natural language, flowcharts or pseudocode before being coded.
Searching and efficiency
Efficiency compares how the resources needed grow with the size of the input.
- Linear (sequential) search checks each element in turn and works on unsorted data; binary search repeatedly halves a sorted list and is much faster.
- Binary search needs the data to be sorted; each step eliminates half of the remaining items.
- An algorithm runs in reasonable time if the steps grow as a polynomial (such as n or n squared) of the input size; exponential growth is unreasonable.
- Some problems are undecidable: no algorithm can solve them for all inputs (the halting problem).
Heuristics and simulations
When exact solutions are impractical, approximations and models help.
- A heuristic finds an approximate solution quickly when an exact one would take too long.
- Simulations model real-world systems, allowing experiments that are costly or dangerous; they simplify reality and may leave out factors.
- Randomness is used in simulations and games; results vary each run.
Binary search only works on sorted data.
A faster-looking algorithm is not always better if the data is small; efficiency matters as input size grows.
Unit 5: Programming
▾Variables, expressions and lists
Programs store values in variables and combine them with operators.
- A variable stores a value that can change; assignment in the AP language is written with an arrow, for example x ← 5.
- Arithmetic operators are +, -, *, / and MOD (the remainder); MOD is used to test divisibility and to wrap around.
- A list is an ordered collection; in the AP language list indexes start at 1; APPEND adds, INSERT puts an item at an index, REMOVE deletes, LENGTH returns the number of items.
- Strings are sequences of characters; concatenation joins strings.
Conditionals and iteration
Control structures determine which statements run and how many times.
- Boolean values are true or false; relational operators (=, ≠, >, <, ≥, ≤) and logical operators (AND, OR, NOT) form conditions.
- IF/ELSE selects between paths; nested conditionals test further conditions.
- REPEAT n TIMES runs a block a set number of times; REPEAT UNTIL runs until a condition becomes true; FOR EACH item IN list visits each element.
- Careful tracing of loops tracks the value of each variable after every iteration.
Procedures and libraries
Procedures organize code into reusable named blocks.
- A procedure (function) has a name, optional parameters and may return a value; calling it runs the code with given arguments.
- Procedural abstraction hides details so you can use a procedure without knowing how it works, which makes programs easier to write and maintain.
- Libraries and APIs provide existing code; using them speeds development; RANDOM(a, b) returns a random integer from a to b inclusive.
- Parameters make a procedure general; global and local variables differ in where they can be used.
In the AP pseudocode, list indexes start at 1, not 0.
MOD gives the remainder, not the quotient; 17 MOD 5 is 2.
Unit 6: Computer Systems and the Internet
▾The Internet and how data travels
The Internet is a network of networks using shared protocols.
- A computing device sends data in packets, small chunks that are routed independently and reassembled at the destination.
- Protocols such as IP (addressing and routing), TCP (reliable delivery) and HTTP (web pages) are open standards that let different systems communicate.
- The Domain Name System (DNS) translates domain names into IP addresses.
- Bandwidth is the maximum amount of data per second; latency is the delay; a download time is the file size divided by the bandwidth.
Fault tolerance and routing
The Internet is designed to keep working when parts fail.
- Routing is dynamic: routers choose paths, and redundant paths mean data can be rerouted around failures (fault tolerance).
- Redundancy improves reliability but costs more resources.
- The Internet is scalable because the protocols let new devices and networks join without central control.
Parallel and distributed computing
Splitting work across processors can speed up computation.
- Sequential computing runs one step at a time; parallel computing runs parts simultaneously on multiple processors; distributed computing uses multiple devices.
- Speedup is the time of sequential execution divided by the time of parallel execution.
- Not all tasks can be parallelized; steps that depend on earlier results must wait.
- Parallel solutions can solve problems that would be too large for a single computer.
The Internet and the World Wide Web are not the same: the web is a service that runs on the Internet.
Bandwidth is a maximum rate, while latency is delay.
Unit 7: Cybersecurity and Privacy
▾Threats to security
Cybersecurity protects data and systems from unauthorized access.
- Phishing tricks people into revealing information; keylogging records keystrokes; malware is malicious software; rogue access points imitate trusted networks.
- A distributed denial-of-service (DDoS) attack overwhelms a service with traffic from many devices.
- Strong, unique passwords and multifactor authentication reduce the risk of account takeover.
Encryption
Encryption protects information by making it unreadable without a key.
- Symmetric encryption uses the same key to encrypt and decrypt; public-key (asymmetric) encryption uses a public key to encrypt and a private key to decrypt.
- Public-key encryption lets people who have never met exchange secure messages; it underlies HTTPS.
- Certificate authorities help verify that a website's public key belongs to the claimed owner.
Privacy and personal data
Collecting and sharing data creates privacy risks.
- Personally identifiable information (PII) is data that can identify a person, such as a name or address.
- Websites and apps collect data through cookies, location services and user accounts; users can review privacy settings.
- Combining multiple data sets can reveal identities even when each alone seems harmless.
Encryption does not hide that a message exists; it protects the contents.
In public-key encryption the public key can be shared widely, but the private key must stay secret.
Unit 8: Impact of Computing
▾Beneficial and harmful effects
Computing innovations affect society in many ways, some unintended.
- Innovations can transform health care, education and communication but may also cause harm, such as job displacement or privacy loss.
- The digital divide is the gap between people with and without access to computers and the Internet; it can widen inequality.
- Computing bias arises when data or design reflects human prejudice, for example in facial recognition or hiring algorithms.
Crowdsourcing and citizen science
Large groups of people can contribute data and solve problems.
- Crowdsourcing gathers contributions from many people online; citizen science lets volunteers help with research.
- Open data sets and open-source software share work widely; contributors benefit from many perspectives.
Legal and ethical issues
Intellectual property and licensing govern how work can be used.
- Copyright protects creators; Creative Commons licenses let creators allow certain uses of their work.
- Open-source software lets anyone view and modify the code; licenses specify the conditions.
- Citing sources and obtaining permission respects the rights of creators; plagiarism is presenting others' work as your own.
- Computing has an energy footprint; data centers consume large amounts of electricity.
Using data or an algorithm does not make a decision objective; bias in the data can be reproduced by the program.
Free to view does not mean free to reuse; check the license.
Term
Click or press Enter to flip · Rate yourself to track weak cards
Browse all 80 flashcards as a list
Unit 1: Creative Development
- Iterative development
- A process of repeatedly designing, testing, getting feedback and revising a program.
- Pair programming
- Two programmers working together at one computer, one writing code and the other reviewing.
- Syntax error
- A mistake that breaks the rules of the programming language, preventing the program from running.
- Logic error
- A mistake that lets a program run but produces incorrect results.
- Runtime error
- An error that occurs while a program is running, such as dividing by zero.
- Overflow error
- An error that occurs when a value is too large to be stored with the available bits.
- Debugging
- Finding and fixing errors in a program.
- Prototype
- An early model of a program used to test ideas and collect feedback.
- Event
- An action, such as a click or key press, that triggers part of a program.
- Comment
- Text in code that explains it to people and is ignored by the computer.
Unit 2: Data Representation
- Bit
- A single binary digit, either 0 or 1.
- Byte
- A group of 8 bits.
- Binary
- A number system that uses only the digits 0 and 1.
- Analog data
- Data with values that change continuously, such as sound waves.
- Sampling
- Measuring an analog signal at regular intervals to digitize it.
- Pixel
- A single colored dot in a digital image.
- RGB
- A color model that represents color with red, green and blue values.
- Lossless compression
- Compression that allows the original data to be restored exactly.
- Lossy compression
- Compression that permanently removes some data to make files smaller.
- Metadata
- Data that describes other data, such as the time a photo was taken.
Unit 3: Data Analysis and Big Data
- Correlation
- A relationship in which two variables tend to change together.
- Causation
- A relationship in which one event brings about another.
- Big data
- Data sets so large or complex that they require special tools to process.
- Data cleaning
- Fixing or removing errors, duplicates and inconsistencies in a data set.
- Filtering
- Selecting only the data that meet a condition.
- Scalability
- The ability of a system to handle growth in data or users.
- Bias in data
- Systematic distortion in how data was collected, which can lead to misleading conclusions.
- Visualization
- A chart or graph that shows patterns in data.
- Personally identifiable information (PII)
- Information that can be used to identify a person.
- Transforming data
- Changing data into another form, such as converting units.
Unit 4: Algorithms
- Algorithm
- A finite set of instructions that accomplishes a task or solves a problem.
- Sequencing
- Performing the steps of an algorithm in order.
- Selection
- Choosing between steps based on a condition.
- Iteration
- Repeating a set of steps.
- Linear search
- Checking each item in a list one by one until the target is found.
- Binary search
- Repeatedly halving a sorted list to find a target quickly.
- Heuristic
- An approach that finds an approximate solution quickly when an exact one would take too long.
- Undecidable problem
- A problem for which no algorithm can give a correct answer for every input.
- Simulation
- A computer model of a real-world system used to explore how it behaves.
- Reasonable time
- Running time that grows as a polynomial of the input size, rather than exponentially.
Unit 5: Programming
- Variable
- A named storage location whose value can change.
- Assignment
- Giving a variable a value, written x ← 5 in the AP language.
- MOD
- An operator that gives the remainder of a division.
- List
- An ordered collection of items; AP list indexes start at 1.
- Boolean
- A value that is either true or false.
- Conditional
- A statement that runs code only if a condition is true (IF/ELSE).
- Procedure
- A named block of code that can be called, with optional parameters and a return value.
- Parameter
- A variable in a procedure definition that receives an argument when called.
- Procedural abstraction
- Using a procedure without needing to know how it works internally.
- Library
- A collection of existing procedures that programmers can reuse.
Unit 6: Computer Systems and the Internet
- Packet
- A small chunk of data sent across a network and reassembled at the destination.
- IP address
- A number that identifies a device on a network.
- DNS
- The Domain Name System, which translates domain names into IP addresses.
- Protocol
- An agreed set of rules for communication.
- Bandwidth
- The maximum amount of data that can be sent over a connection in a given time.
- Latency
- The delay between sending and receiving data.
- Fault tolerance
- The ability of a system to keep working when parts fail.
- Router
- A device that forwards packets toward their destination.
- Parallel computing
- Running parts of a task at the same time on multiple processors.
- Speedup
- Sequential running time divided by parallel running time.
Unit 7: Cybersecurity and Privacy
- Phishing
- Tricking people into revealing sensitive information by pretending to be a trusted source.
- Malware
- Software designed to damage or gain unauthorized access to a system.
- DDoS attack
- An attack that overwhelms a service with traffic from many devices.
- Encryption
- Scrambling data so only someone with the key can read it.
- Symmetric encryption
- Encryption that uses the same key to encrypt and decrypt.
- Public-key encryption
- Encryption using a public key to encrypt and a private key to decrypt.
- Multifactor authentication
- Verifying identity with two or more kinds of evidence.
- Keylogger
- Software that records what a user types.
- Cookie
- A small file a website stores on a device to remember information about a visit.
- HTTPS
- A version of HTTP that encrypts web traffic.
Unit 8: Impact of Computing
- Digital divide
- The gap between people who have access to computers and the Internet and those who do not.
- Computing bias
- Unfair outcomes from a program because of biased data or design.
- Crowdsourcing
- Getting ideas, data or work from a large group of people, often online.
- Citizen science
- Research in which volunteers help collect or analyze data.
- Creative Commons
- A set of licenses that let creators allow certain uses of their work.
- Open source
- Software whose source code is available for anyone to view and modify.
- Plagiarism
- Presenting another person's work as your own.
- Intellectual property
- Creations of the mind, such as writing, art and code, protected by law.
- Unintended effect
- A result of a computing innovation that its creators did not plan.
- Energy footprint
- The amount of energy used by computing devices and data centers.
Try each problem on your own first — then reveal the solution one step at a time. Mark “Got it” to track your progress.
Unit 2: Data Representation
Binary to decimal
Convert the binary number 101101 to decimal.
Decimal to binary
Convert the decimal number 37 to binary.
How many bits are needed?
A game has 90 different characters. What is the minimum number of bits needed to give each character a unique binary code?
File size of an image
A 200 by 100 pixel image uses 24 bits per pixel. How many bytes does it take without compression?
Unit 4: Algorithms
Binary search steps
How many comparisons does binary search need at most to find an item in a sorted list of 1,000 items?
Unit 5: Programming
Tracing a loop
What does this code display? total ← 0; FOR EACH n IN [3, 5, 8]: IF (n MOD 2 = 1): total ← total + n; DISPLAY(total).
MOD for even or odd
Write a condition that is true when n is odd, and explain it.
Unit 6: Computer Systems and the Internet
Download time
A 450 megabyte file is downloaded at 15 megabytes per second. How long does the download take?
Speedup with parallel processors
A task takes 80 seconds sequentially. In a parallel version, 10 seconds must run sequentially and the other 70 seconds split evenly among 7 processors. What is the speedup?
Unit 1: Creative Development
Collaboration and the development process
Programs are built by people working together through planning, testing and revision.
Purpose, requirements and user feedback
Good programs begin with a clear purpose and are tested with real users.
Errors and debugging
Programmers expect errors and use strategies to find and fix them.
Unit 2: Data Representation
Binary numbers and bits
Computers represent all information using bits, each either 0 or 1.
Representing text, images and sound
All kinds of data are encoded as bits using agreed-upon formats.
Compression
Compression reduces the number of bits needed to store or send data.
Unit 3: Data Analysis and Big Data
Extracting information from data
Data can be examined for patterns and used to draw conclusions.
Big data and data sets
Computers can analyze extremely large collections of data.
Processing data with programs
Programs filter, sort and combine data to answer questions.
Unit 4: Algorithms
What an algorithm is
An algorithm is a finite set of instructions that accomplishes a task.
Searching and efficiency
Efficiency compares how the resources needed grow with the size of the input.
Heuristics and simulations
When exact solutions are impractical, approximations and models help.
Unit 5: Programming
Variables, expressions and lists
Programs store values in variables and combine them with operators.
Conditionals and iteration
Control structures determine which statements run and how many times.
Procedures and libraries
Procedures organize code into reusable named blocks.
Unit 6: Computer Systems and the Internet
The Internet and how data travels
The Internet is a network of networks using shared protocols.
Fault tolerance and routing
The Internet is designed to keep working when parts fail.
Parallel and distributed computing
Splitting work across processors can speed up computation.
Unit 7: Cybersecurity and Privacy
Threats to security
Cybersecurity protects data and systems from unauthorized access.
Encryption
Encryption protects information by making it unreadable without a key.
Privacy and personal data
Collecting and sharing data creates privacy risks.
Unit 8: Impact of Computing
Beneficial and harmful effects
Computing innovations affect society in many ways, some unintended.
Crowdsourcing and citizen science
Large groups of people can contribute data and solve problems.
Legal and ethical issues
Intellectual property and licensing govern how work can be used.
Common mistakes for each unit — read the mistake, then make sure you know why it's wrong.
Unit 1: Creative Development
Watch out
A program that runs without crashing can still contain a logic error; testing must check the output, not just that it ran.
Watch out
Collaboration does not mean everyone writes every line; roles and communication matter.
Unit 2: Data Representation
Watch out
The number of values with n bits is 2 to the n, but the largest value is 2^n minus 1 because counting starts at 0.
Watch out
Lossy compression cannot restore the original data; lossless can.
Unit 3: Data Analysis and Big Data
Watch out
A strong correlation is not proof of cause.
Watch out
Anonymized data can sometimes be re-identified when combined with other data sets.
Unit 4: Algorithms
Watch out
Binary search only works on sorted data.
Watch out
A faster-looking algorithm is not always better if the data is small; efficiency matters as input size grows.
Unit 5: Programming
Watch out
In the AP pseudocode, list indexes start at 1, not 0.
Watch out
MOD gives the remainder, not the quotient; 17 MOD 5 is 2.
Unit 6: Computer Systems and the Internet
Watch out
The Internet and the World Wide Web are not the same: the web is a service that runs on the Internet.
Watch out
Bandwidth is a maximum rate, while latency is delay.
Unit 7: Cybersecurity and Privacy
Watch out
Encryption does not hide that a message exists; it protects the contents.
Watch out
In public-key encryption the public key can be shared widely, but the private key must stay secret.
Unit 8: Impact of Computing
Watch out
Using data or an algorithm does not make a decision objective; bias in the data can be reproduced by the program.
Watch out
Free to view does not mean free to reuse; check the license.