Differences between RAM and ROM

Tip: Choose Save as PDF in the print dialog to download. Use A4 paper size.

Differences between RAM and ROM

Name:
Date:
Class:

Quick Questions

Shade in the A or B circle for each question.

1. Which type of memory loses its contents when the power is switched off?
A RAM
B ROM
2. Which statement about ROM is correct?
A ROM is non-volatile and keeps its data without power
B ROM is volatile and loses its data without power
3. Can the CPU normally write new data to RAM?
A No, RAM is read only
B Yes, RAM is read/write
4. Can the CPU normally change the data stored in ROM?
A Yes, ROM is read/write
B No, ROM is read only
5. Where is the data and program you are currently using stored?
A RAM
B ROM

Match the Pairs

Draw a line connecting each item on the left to its match on the right.

Left columnRight column
1RAM: volatile ARAM loses all of its contents when the power is turned off
2ROM: non-volatile BROM is non-volatile, so it keeps its data without power. RAM is the volatile memory.
3RAM is read/write, so the CPU can both read data from it and save new data to it while programs run CThe roles are swapped. RAM stores programs and data in use, and ROM stores the start-up instructions.
4ROM holds the start-up instructions (bootstrap) the computer needs to begin working, and the CPU can only read them DROM: read only, boot instructions
5ROM is volatile and loses its data when the power is off EROM keeps its contents when the power is turned off
6RAM stores the start-up instructions and ROM stores the open programs FRAM: read and write

Definitions

RAM vs ROM

Fill in the Blanks

Complete each line of code by filling in the missing parts.

1.
RAM.volatile ← ____ ROM.volatile ← FALSE
2.
ROM.access ← _________ RAM.access ← READ_WRITE
3.
ROM.holds ← ____________________ RAM.holds ← programs_in_use
4.
IF RAM.size _ ROM.size THEN OUTPUT "RAM is larger" ENDIF
5.
RAM.holds ← _______________ ROM.holds ← startup_instructions

Spot the Error

Shade in the letter of the line that contains an error.

Question 1
A ram_volatile = True
B ram_writable = True
C ram_holds = "open programs"
D ram_size = "small"
Question 2
A if memory == "ROM":
B print("Non-volatile")
C print("Read only")
D print("Larger than RAM")
Question 3
A if memory == "ROM":
B print("Data is lost")
C print("Volatile")
Question 4
A memory = "ROM"
B can_cpu_write = False
C holds = "open programs"
Question 5
A memory = "RAM"
B can_cpu_write = False
C holds = "open programs"

Answer Key

Differences between RAM and ROM
Section A: Quick Questions
Q1
A — RAM
Q2
A — ROM is non-volatile and keeps its data without power
Q3
B — Yes, RAM is read/write
Q4
B — No, ROM is read only
Q5
A — RAM
Section B: Match the Pairs
Q1
RAM: volatile → RAM loses all of its contents when the power is turned off
Q2
ROM: non-volatile → ROM keeps its contents when the power is turned off
Q3
RAM is read/write, so the CPU can both read data from it and save new data to it while programs run → RAM: read and write
Q4
ROM holds the start-up instructions (bootstrap) the computer needs to begin working, and the CPU can only read them → ROM: read only, boot instructions
Q5
ROM is volatile and loses its data when the power is off → ROM is non-volatile, so it keeps its data without power. RAM is the volatile memory.
Q6
RAM stores the start-up instructions and ROM stores the open programs → The roles are swapped. RAM stores programs and data in use, and ROM stores the start-up instructions.
Section C: Definitions
Q1
RAM vs ROM — RAM is volatile, read/write and holds running programs; ROM is non-volatile, read only and holds start-up instructions. RAM is larger.
Section D: Fill in the Blanks
Q1
RAM.volatile ← TRUE ROM.volatile ← FALSE
Q2
ROM.access ← READ_ONLY RAM.access ← READ_WRITE
Q3
ROM.holds ← startup_instructions RAM.holds ← programs_in_use
Q4
IF RAM.size > ROM.size THEN OUTPUT "RAM is larger" ENDIF
Q5
RAM.holds ← programs_in_use ROM.holds ← startup_instructions
Section E: Spot the Error
Q1
D — RAM is larger than ROM, so ram_size should be "large", not "small".
Q2
D — ROM is usually much smaller than RAM, so the line should say "Smaller than RAM".
Q3
A — It is RAM that is volatile and loses its data when the power is off. ROM is non-volatile, so the condition should test for "RAM".
Q4
C — ROM holds the start-up (boot) instructions. Programs that are currently in use are held in RAM.
Q5
B — RAM is read/write, so the CPU can write to it. can_cpu_write should be True.