How a Computer "Thinks" - Hardware Basics

The basic hardware of modern computers, explained for people who never wanted to study electrical engineering.

Fundamentals 12 min Beginner April 13, 2026

Right now, as you read this sentence, billions of tiny switches inside your device are flipping between "on" and "off." That is literally the only thing a computer can do. How does flipping switches let you watch videos, write messages, or talk to an AI?

The answer starts with three physical components you can actually hold in your hands - and a surprisingly simple alphabet of ones and zeros. By the end of this article, you will understand what happens inside your device every time you open an app, and why the same hardware now powers artificial intelligence.

The Team Inside Your Computer: CPU, RAM, and Storage

CPU, RAM, and Storage

AnalogyDefinition
Think of an office: a clerk (CPU) sits at a desk (RAM) with an archive room down the hall (SSD/hard drive). The clerk can only work on papers that are on the desk. Fetching from the archive is slow, so frequently needed files stay on the desk. When you leave for the night (power off), the desk is cleared - but the archive remains.

Where the office analogy breaks: a real desk is not 100,000 times faster to reach than a real filing cabinet. In a computer, the speed differences really are that extreme - RAM is roughly 100,000 times faster than a hard drive for random access.

~100 ns
RAM Access Volatile but extremely fast
~100 µs
SSD Access 1,000x slower than RAM
~10 ms
Hard Drive Access 100,000x slower than RAM
1
The operating system reads the program data (several megabytes) from the SSD
2
Program and document are loaded into RAM
3
The CPU reads instructions from RAM and executes them
4
The GPU renders the window and displays text on screen
5
When you save, changes are written from RAM back to the SSD

Common Misconception: Storage Space vs. Working Memory

"Storage is full" can mean two different things: either the SSD is full (no more room for files) or RAM is maxed out (programs become slower). These are completely different problems with different solutions.

"More RAM = faster computer" is only partially true. More RAM prevents data from being swapped to the slower SSD. But actual computing speed depends on the CPU.

Why Does Your Computer Have Two Brains?

Besides the CPU, most computers contain a second processor: the GPU (Graphics Processing Unit). While the CPU has few but very powerful cores, a modern GPU has thousands of simpler cores that work simultaneously.

Think of the CPU as a university professor who can solve any problem - but only one at a time. The GPU is like a stadium of 10,000 school children solving simple addition problems simultaneously. For one complex integral, the professor wins. For coloring 8 million pixels per frame, the stadium wins by a landslide.

The analogy has limits: GPU cores are not "dumb" - they can execute various operations, have their own registers and caches, and are coordinated by sophisticated scheduling hardware.

Why Parallelism Is Essential

A 4K display has 3,840 x 2,160 = roughly 8.3 million pixels. At 60 frames per second, that means 500 million pixel updates per second - with color, lighting, and shadows. That easily adds up to billions of operations per second, far more than a CPU can handle alone.

CPU

Few powerful cores (e.g., 8). Flexible, fast context switching. Ideal for complex, sequential tasks: operating system, program logic, decisions.

GPU

Thousands of simpler cores (e.g., 10,000+). Massively parallel. Ideal for identical calculations on many data points: pixel rendering, matrix operations, AI training.

Neural networks are fundamentally built on matrix multiplications - thousands of identical calculations on large number arrays. Exactly what GPUs do best.

With NVIDIA CUDA (2007), it became practical for the first time to use GPUs for general-purpose computing beyond graphics. Since then, GPU manufacturers have introduced specialized Tensor Cores that are particularly efficient for AI workloads.

Common Misconception: "GPUs Are Only for Gaming"

Graphics cards were long associated with gaming. Today, GPUs are central components in data centers for science, medicine, and especially AI development. And: more GPU memory (VRAM) does not automatically mean more frames per second - VRAM determines how much data can be processed simultaneously.

Interactive: GPU Data Explorer

Sort and filter real GPU models by VRAM, compute power (TFLOPS), power consumption, and price. Compare gaming cards with datacenter GPUs and observe why the A100 and H100 cost so much more — and why VRAM is crucial for AI models.

GPU Comparison for AI

Auto

10 of 10 GPUs

GPU VRAM TFLOPS TDP Price Year
H100 SXM NVIDIA 80 GB989700 W$30,0002023
A100 80GB NVIDIA 80 GB312300 W$15,0002020
RTX 4090 NVIDIA 24 GB82.6450 W$1,5992022
RX 7900 XTX AMD 24 GB61.4355 W$9492022
RTX 4080 NVIDIA 16 GB48.7320 W$1,1992022
RTX 4070 Ti NVIDIA 12 GB40.1285 W$7992023
RTX 3090 NVIDIA 24 GB35.6350 W$9002020
M2 Ultra Apple 192 GB27.2150 W$4,3992023
RTX 4060 Ti 16GB NVIDIA 16 GB22.1165 W$4992023
RX 7600 AMD 8 GB21.5165 W$2692023

H100 SXM

Top-tier datacenter GPU (TFLOPS = Tensor Core FP16). Transformer Engine for optimal LLM training. Price highly variable (25,000-40,000 USD depending on availability).

VRAM
80 GB
TFLOPS
989
TDP
700 W
Efficiency
1.4 TFLOPS/W
Tip: For local LLM inference (e.g., a 7B model in INT4), 6 GB VRAM is sufficient. For training or larger models, 24+ GB are needed. The TFLOPS/Watt efficiency shows how much computing power is achieved per watt of electricity. Note: TFLOPS values of consumer GPUs (Shader) and datacenter GPUs (Tensor Core) are not directly comparable.

The Digital Alphabet: Bits, Bytes, and Binary Code

A bit (binary digit) is the smallest unit of information and can have exactly two states: 0 or 1. A byte consists of 8 bits and allows 256 different combinations. Computers use binary because transistors - their building blocks - have two reliable states: conducting (on/1) and blocking (off/0).

Morse code transmits messages with just two signal types - short and long. Similarly, the binary system encodes everything with 0s and 1s. Different combinations produce different meanings, and the "language" is determined by the interpreting system, not by the pattern itself.

The analogy breaks because Morse code is time-based: signal duration is part of the encoding. Bits, however, are position-based - each bit in a byte has a fixed positional value: 128, 64, 32, 16, 8, 4, 2, 1.

Step by Step: The Letter "A" in Binary Code

1
"A" has the decimal value 65 in the ASCII code
2
Positional values of a byte: 128 | 64 | 32 | 16 | 8 | 4 | 2 | 1
3
Binary: 0100 0001 — only positions 64 and 1 are "on"
4
64 + 1 = 65 = "A" - the same bit pattern could also mean the number 65 or a brightness value

The key insight: the pattern 01000001 has no built-in meaning. Only the program reading the bits decides whether it represents a letter, a number, or something else entirely.

1 Byte
One Letter A single ASCII character
~5 MB
A Smartphone Photo Millions of color values per pixel
~14 GB
A Large AI Model Billions of weight values

Why bits and bytes matter for the rest of the learning path: terms like "32-bit float," "8-bit quantization," or "tokenization" build directly on this understanding. Mastering the digital alphabet helps you grasp future technical terms more quickly.

Key Takeaways

  1. The CPU is the brain that executes instructions step by step - fast and flexible, but limited to a few tasks at a time.
  2. RAM is the short-term workspace: blazingly fast but volatile - everything vanishes when the power goes out.
  3. SSD/hard drive is the long-term archive: persistent but thousands of times slower than RAM for random access.
  4. The GPU contains thousands of simpler cores that work in parallel - originally for graphics, now the engine behind AI training.
  5. Every piece of digital data - text, images, AI models - is ultimately encoded in bits (zeros and ones), just at vastly different scales.

Quiz: Hardware Basics

Question 1 / 4
Not completed

What happens to the contents of RAM during a power outage?

Select one answer
Answer Key: 1) B · 2) C · 3) C · 4) C

Comprehension Check

  • Your laptop crashes and the screen goes black. After rebooting, your unsaved document is gone. Why?
  • An AI developer is training a neural network. The CPU is at 5% usage, the GPU at 98%. Explain why this is normal.
  • You see the bit pattern 01000001. Your text editor shows "A", your calculator shows "65". Explain the difference.