AP Computer Science Principles · Unit 4 · 11-15% of the exam · about 75 minutes
Unit 4: Computer Systems and Networks
By the end: Explain how data crosses the internet in packets using open protocols, analyze a network drawing for paths, redundancy and single points of failure, and compute the time and speedup of sequential, parallel and distributed solutions.

- 4.1 Computing devices, systems and networks · 8 min
What the internet actually is
- Computing device: a physical thing that runs programs. Computing system: devices and programs working toward one purpose. Network: connected devices that send and receive data.
- The internet is a network of networks.
- A path is a sequence of directly connected devices from sender to receiver, with no device repeated. Routing is finding a path.
- 4.1 Bandwidth · 6 min
How much data per second
- Bandwidth: the maximum data sent in a fixed time, measured in bits per second.
- Transfer time ≈ size in bits ÷ bandwidth. Multiply bytes by 8 first.
- Latency is the time for one trip. More bandwidth does not shrink latency.
- 4.1 Packets, routing and scalability · 9 min
Messages travel in pieces
- Data is sent as packets: a chunk of data plus metadata (destination, source, packet number).
- Packets can take different paths and arrive in order, out of order, or not at all.
- The receiver uses the metadata to reassemble the message.
- 4.1 Protocols: IP, TCP and UDP · 9 min
Rules everyone agrees to follow
- A protocol is an agreed-upon set of rules. The internet's protocols are open (nonproprietary), so anyone can build devices that join.
- IP: addresses and routes packets. TCP: guarantees delivery and order, resending lost packets. UDP: sends with no checks, less delay, possible loss.
- Choose TCP when losing data is worse, UDP when waiting is worse.
- 4.1 The World Wide Web and HTTP · 6 min
The internet is not the Web
- The World Wide Web is a system of linked pages, programs and files. It runs on the internet.
- HTTP is the Web's protocol: a browser requests a page, a server responds.
- Email apps, video calls and online games use the internet without being the Web.
- 4.2 Fault tolerance and redundancy · 9 min
Built to survive broken parts
- Fault tolerant: the system keeps working when some parts fail.
- Redundancy: extra components, mainly extra paths, that take over when others fail. It costs extra hardware.
- A single point of failure is a connection or device whose failure alone cuts devices off.
- 4.2 Analyzing failures · 7 min
Find the weak spot
- Count paths by first step, then second, with no device repeated.
- Minimum failures: test singles, then pairs. The first size that works is the answer.
- A device can be a single point of failure even when no single connection is.
- 4.3 Sequential and parallel computing · 9 min
Many processors, one job
- Sequential time = the sum of all steps.
- Parallel time = sequential part + longest parallel part (the busiest processor).
- Speedup = sequential time ÷ parallel time. Sequential on top, no units.
- 4.3 Speedup and its limits · 8 min
Why more processors stop helping
- Speedup is limited by uneven tasks and by the sequential portion.
- Adding processors helps less and less, and eventually stops helping in a meaningful way.
- The time can never drop below the sequential portion, however many processors you add.
- 4.3 Distributed computing · 6 min
When one computer is not enough
- Distributed computing: several separate devices on a network each run part of a program.
- It solves problems too large for one computer in processing time or storage, and solves big problems faster.
- Sending and combining data adds sequential time that limits the speedup.
- Unit 4 wrap-up · 7 min
Put it together