RAM and ROM are both types of computer memory. RAM is used to store computer programs and data that CPU needs in real time. RAM data is volatile and is erased once computer is switched off. ROM have prerecorded data and it is used to boot computer. RAM data is static and remains in the computer even if computer is switched off.
Following are the important differences between RAM and ROM.
|1||Definition||RAM stands for Random Access Memory.||ROM stands for Read Only Memory.|
|2||Data Retention||RAM data is volatile. Data is present till power supply is present.||ROM data is permanent. Data remains even after power supply is not present.|
|3||Data Access||RAM data can be read, erased or modified.||ROM data is readonly.|
|4||Usage||RAM is used to store data that CPU needs for current instruction processing.||ROM is used to store data that in needed to bootstrap the computer.|
|5||Speed||RAM speed is quite high.||ROM speed is slower than RAM.|
|6||CPU Access||CPU can access data stored on RAM.||Data to be copied from ROM to RAM so that CPU can access its data.|
|7||Capacity||RAM memory is large and high capacity.||ROM is generally small and of low capacity.|
|8||Usage||RAM is used as CPU Cache, Primary Memory.||ROM is used as firmware by microcontrollers.|
|9||Cost||RAM is costly.||ROM is cheap.|