Theory
The power-cut test
A power cut hits the shop mid-afternoon. When the billing PC restarts, the half-finished bill you were typing is gone, yet the machine itself wakes up knowing exactly how to boot, checks its parts, and loads everything cleanly.
One machine, one power cut, two opposite behaviours: something forgot instantly, and something remembered perfectly.
That split is the entire memory chapter: RAM forgets, ROM remembers.
Theory
The desk and the instruction book
RAM is Chirag's work desk: everything he is currently working on is spread across it, instantly reachable, but cleared every night (power off = desk wiped). ROM is the laminated instruction book bolted to the wall: how to open the shop, where the keys are. Nobody writes on it day to day; it survives every night, every power cut, every year.
Theory
RAM and its three exam types
RAM (Random Access Memory): read-write, volatile (contents vanish at power-off), holds running programs and their data. "Random access" means any address is equally quick to reach.
- SRAM (Static): stores bits in flip-flop circuits. No refreshing needed, very fast, expensive, power-hungry per bit. Lives in cache.
- DRAM (Dynamic): stores bits as charge in tiny capacitors that leak, so it must be refreshed thousands of times per second. Slower but cheap and dense: your main memory.
- SDRAM (Synchronous DRAM): DRAM synchronised to the system clock for orderly, faster transfers. Its descendants are the DDR sticks (DDR4, DDR5) Chirag actually sells.
Theory
ROM and its erasable children
ROM (Read Only Memory): non-volatile, written at manufacture, holds the startup firmware (BIOS) that wakes the machine before any disk is touched.
Engineers then wanted correctable ROM:
- PROM: programmable once by the buyer, then permanent.
- EPROM: erasable with ultraviolet light shone through a small quartz window on the chip, then reprogrammable.
- EEPROM: erasable electrically, in place, no lamp needed. Refined further, this idea became the flash memory in pen drives and SSDs.
At a glance
The memory family at a glance
| Type | Volatile? | Known for |
|---|---|---|
| SRAM | Yes | Flip-flops, no refresh, cache memory |
| DRAM | Yes | Capacitors, needs refresh, main memory |
| SDRAM | Yes | Clock-synchronised DRAM (DDR family) |
| ROM | No | Factory-written boot firmware |
| EPROM | No | Erased by UV light (quartz window) |
| EEPROM | No | Erased electrically, ancestor of flash |
Quiz
Why does DRAM need constant refreshing while SRAM does not?
- DRAM stores bits as leaking capacitor charge; SRAM holds them in flip-flop circuits
- DRAM is non-volatile and must sync with the disk
- SRAM is refreshed too, just once per day
- DRAM refreshing is only needed in laptops
Show the answer
DRAM stores bits as leaking capacitor charge; SRAM holds them in flip-flop circuits
A DRAM cell is a capacitor whose charge drains away, so the memory controller re-tops every cell thousands of times a second. SRAM's flip-flops hold their state as long as power flows, no refresh, which also makes SRAM faster and pricier. This one-line comparison is a guaranteed exam pair.
Think first
Think it through
The computer needs instructions to boot, but the disk has not been read yet and RAM woke up empty. Where must the very first instructions live, and why can they not live in RAM?
Show the answer
In ROM. RAM is volatile: at power-on it is blank, so it cannot hold the wake-up instructions. Boot firmware must survive power-off, hence non-volatile ROM. This chicken-and-egg reasoning IS the exam answer for "why is ROM needed when we have RAM?"
Quiz
What is the key difference between EPROM and EEPROM?
- EPROM is erased with UV light; EEPROM is erased electrically
- EPROM is volatile; EEPROM is non-volatile
- EPROM can never be erased; EEPROM erases with UV light
- They differ only in storage capacity
Show the answer
EPROM is erased with UV light; EEPROM is erased electrically
The E-for-erasing method is the whole difference: EPROM needs an ultraviolet lamp and that little quartz window; EEPROM ("electrically erasable") rewrites in place with voltage. Both are non-volatile ROM descendants. Option C reverses the two, the classic exam distractor.
Watch out
Where marks leak
Calling ROM "storage like a hard disk": ROM holds firmware, not your files. Writing "SRAM is dynamic" or swapping the SRAM/DRAM properties: anchor S = Static = Stays (no refresh), D = Dynamic = Drains (refresh). And "random access" does not mean haphazard, it means every address takes equal time.
Theory
Shop sense and what is next
When a customer says "8 GB memory", they mean SDRAM sticks (DDR4/DDR5). When their pen drive survives a format, thank EEPROM's descendant, flash. Last topic's cache? That was SRAM at work. Next topic, storage devices, picks up where ROM's permanence meets real capacity: disks, DVDs and USB drives.
Summary
Key takeaways
- RAM: volatile read-write working memory; ROM: non-volatile firmware home.
- SRAM: flip-flops, no refresh, fast, costly, used in cache.
- DRAM: leaking capacitors, needs refresh, cheap, main memory; SDRAM syncs it to the clock (DDR).
- PROM writes once; EPROM erases by UV light; EEPROM erases electrically.
- Boot instructions must live in ROM because RAM wakes up empty.
- Memory hook: Static Stays, Dynamic Drains; desk vs instruction book.