The internet is a global network of interconnected computers using the TCP/IP protocol.
Key Concepts
- IP Address — unique device identifier
- DNS — domain name resolution
- TCP/UDP — transport protocols
- HTTP/HTTPS — web protocols
The internet is a global network of interconnected computers using the TCP/IP protocol.
# Request flow Browser → DNS → IP → TCP → Server → Response # Ports HTTP: 80 | HTTPS: 443 | SSH: 22
# HTTP request concept (simulated) import json # Simulate an HTTP request request = { "method": "GET", "url": "/api/users", "headers": { "Content-Type": "application/json", "Authorization": "Bearer token123" } } response = { "status": 200, "headers": {"Content-Type": "application/json"}, "body": json.dumps({"users": ["Alice", "Bob"]}) } print("Request:") print(json.dumps(request, indent=2)) print(" Response:") print(json.dumps(response, indent=2))
What happens when you type a URL in the browser?
DNS resolves domain to IP, browser sends HTTP request to server, server responds with HTML, browser renders it.
What port does HTTPS use?
HTTPS uses port 443. HTTP uses port 80.
TCP is reliable and ordered. UDP is faster but unreliable. TCP for web/email, UDP for gaming/streaming.