Memory and Storage

 RAM
Random Access Memory
HDD
Hard Disk Drive
SSD
Solid State Drive 
NVMe SSDs
Non-Volatile Memory Express
Primary
Function
Temporary storage of files and programs (open files)Permanent low speed storage of all programs and dataPermanent fast speed storage of all programs and dataPermanent  very fast speed storage
Typical
Capacity
Smaller amount (typically 4 GB - 16 GB).Larger amount (240GB to 2 TB or more).500GB
to 8TB 
500GB
to 8TB 
Nature of
Storage
Temporary storage of files and programsPermanent storage of files and programsPermanent storage of files and programsPermanent storage of files and programs
AnalogyLike your real desktop - has only your open, current workLike a file cabinet - has long-term storage - copies files slowlyLike a high-speed searchable room of files - huge files like a DVD are copied in minutesEven faster - huge files are copied in seconds
Data
Retention
(Power Off)
Contents disappear when you  power off the computerContents remain when you power off the computerContents remain when you power off the computerContents remain when you power off the computer
Data
Retention
(System
Crash)
Contents disappear when the computer crashesContents remainContents remainContents remain
Physical
Composition
Consists of chips (integrated circuits)Consists of a HDD (spinning disks and movable read/write heads)Consists of chips (NAND flash memory)Consists of chips (NAND flash memory)
Data
Handling
(Save)
A temporary copy of the opened file(s) and all changes are kept in RAM until the file(s) is saved.Until your changes are saved, the original file(s) remains on the HDD. Once saved, the new changes are written to the HDD.Until your changes are saved, the original file(s) remains on the SSD. Once saved, the new changes are written to the SSD.Optimizes the speed at which changes are written to compatible SSDs.
SpeedFast and getting faster.Slower (mechanical parts)Much faster than HDDs.Significantly faster than SATA-based SSDs
Connection
Type
Connected via DIMM slots on the motherboard.Typically connected via SATA IDE interface.Typically connected via SATA or NVMe (M.2) interface.Utilizes PCIe M.2 or U.2 for the fastest connection
Impact on
Performance
Crucial for multitasking, video editing, and gamingAffects boot times and overall application loading/saving speedsDramatically improves boot times and application responsivenessProvides the highest performance 
CostHigher cost per GB compared to HDDs.Lower cost per GB compared to SSDs.Higher cost per GB than HDDs, but decreasing.Generally higher due to performance benefits.
Primary
Advantage
Fast, temporary workspace for active data.Large, inexpensive, permanent storage.Fast, durable, and more compact permanent storage.Ultra-fast data transfer for modern storage.