Skip to content
Core CSintermediate · 60 min

Computer Networks

How data moves across the internet: the layered model, TCP vs UDP, what really happens in an HTTP request, DNS, TLS, and why latency and reliability are designed-for, not assumed.

The layered model

The TCP/IP stack layers responsibilities: link (Ethernet/Wi-Fi), internet (IP routing/addressing), transport (TCP/UDP), application (HTTP, DNS). Each layer adds/strips a header. Layering lets parts evolve independently.

TCP vs UDP

TCP is connection-oriented and reliable: a 3-way handshake, ordered delivery, retransmission, and congestion/flow control — at the cost of latency. UDP is connectionless and unreliable but fast and lightweight — good for DNS, video, gaming where speed beats perfect delivery.

Anatomy of a request

Typing a URL: DNS resolves the hostname to an IP → TCP connection (and TLS handshake for HTTPS) → HTTP request/response → the browser renders. DNS caching, keep-alive connections, and CDNs cut repeated latency. Status codes and headers carry metadata.

Resources

Practice & test yourself

Take the quiz →