Skip to content
IGCSE·Tuition
Computer Science · Practice

Hardware and processing: original mixed practice with explanations

Practice helps most when every wrong answer tells you which skill to revisit, not only that you lost a mark.

This set covers the whole of hardware and processing: the instruction cycle, registers, memory and storage, input and output choices, and keeping claims inside the model. The questions go from easy to harder.

Attempt each one on paper first. Use the restricted pseudocode trace trainer or the safe Python reasoning sandbox only to check a trace after you have written your own.

Questions

Question 1 (easy)

State what the program counter (PC) holds and when its value changes in the simplified cycle.

Show answer

The PC holds the address of the next instruction to fetch. It increases by 1 during every fetch. A jump instruction overwrites it with a new address during the execute stage.

Question 2 (easy)

Name the register for each description: (a) holds an address being read, (b) holds the instruction being decoded, (c) holds the result of an addition.

Show answer

(a) MAR. (b) CIR. (c) ACC.

Question 3 (easy)

Which of RAM, ROM and secondary storage (a) loses its contents when the power is off, (b) holds the start-up instructions, (c) keeps a saved homework file?

Show answer

(a) RAM, because it is volatile. (b) ROM, which is non-volatile. (c) Secondary storage, which keeps files without power.

Question 4 (medium)

Complete a trace table for this program. LDA 90 loads the value at address 90, SUB 91 subtracts the value at address 91 from the ACC, STO 92 stores the ACC, and END stops. The PC starts at 50.

AddressContents
50LDA 90
51SUB 91
52STO 92
53END
9015
916
920
Show answer
StepPCMARMDRCIRACC
Start50----
Fetch 15150LDA 90LDA 90-
Execute 1519015LDA 9015
Fetch 25251SUB 91SUB 9115
Execute 252916SUB 919
Fetch 35352STO 92STO 929
Execute 353929STO 929

Check: 15 − 6 = 9. Address 92 now holds 9.

Question 5 (medium)

A laptop has 4 GB of RAM.

Three programs are open, needing 1.2 GB, 2.5 GB and 0.8 GB. (a) How much RAM do they need in total? (b) What happens, and why does it matter?

Show answer

(a) 1.2 + 2.5 + 0.8 = 4.5 GB.

(b) This is 0.5 GB more than the 4 GB of RAM. The computer uses part of secondary storage as virtual memory, swapping data in and out. This is slower than RAM, so the computer slows down.

Question 6 (medium)

A student photographs homework with a phone, edits it on a laptop and saves it. Say where the file is (a) while it is being edited and (b) after the laptop is switched off.

Show answer

(a) The open file is loaded into RAM so the processor can work on it quickly. (b) The saved file stays in secondary storage. RAM would have lost it when the power went off.

Question 7 (medium)

A library lets members borrow books by scanning a card and a book. Choose one input device and one output device and justify each in a sentence.

Show answer

Input: a barcode scanner, because the card and book each carry a code, so scanning records them quickly without typing errors.

Output: a receipt printer (or screen message) confirming the loan and the return date, so the member has proof of what was borrowed.

Question 8 (harder)

Trace this program and state the final value in address 32. JMP 13 sets the PC to 13. The PC starts at 10.

AddressContents
10LDA 30
11JMP 13
12ADD 31
13STO 32
14END
304
31100
320
Show answer
StepPCMARMDRCIRACC
Start10----
Fetch 11110LDA 30LDA 30-
Execute 111304LDA 304
Fetch 21211JMP 13JMP 134
Execute 21311JMP 13JMP 134
Fetch 31413STO 32STO 324
Execute 314324STO 324
Fetch 41514ENDEND4

The jump overwrote the PC (12 became 13), so ADD 31 at address 12 never ran. Address 32 holds 4, not 104.

Question 9 (harder)

A student writes: “This phone has an 8 core processor at 2.8 GHz, so it runs at 22.4 GHz and will always be faster than a 3.0 GHz laptop.” Identify two errors and rewrite the claim.

Show answer

Error 1: cores do not add their clock speeds. 8 × 2.8 = 22.4 is not a valid speed. The clock speed is 2.8 GHz, which is 2.8 billion cycles per second.

Error 2: “always faster” is not supported. Speed also depends on cores, cache, and whether the software can use the cores.

Rewrite: “The phone’s processor runs at 2.8 GHz with 8 cores. The laptop has a higher clock speed (3.0 GHz), but the cores and the type of task also affect performance, so the data given does not show which is faster.”

Question 10 (harder)

Predict the full output of this Python program, which uses the same model as the lessons.

memory = {50: "LDA 90", 51: "ADD 91", 52: "STO 92", 53: "END",
          90: 15, 91: 6, 92: 0}
pc = 50
acc = 0
while True:
    mar = pc
    pc = pc + 1
    mdr = memory[mar]
    cir = mdr
    parts = cir.split()
    op = parts[0]
    if op == "END":
        break
    addr = int(parts[1])
    if op == "LDA":
        acc = memory[addr]
    elif op == "ADD":
        acc = acc + memory[addr]
    elif op == "STO":
        memory[addr] = acc
    print(cir, "ACC =", acc, "PC =", pc)
print(memory[92])
Show answer

The loop prints after each instruction except END:

LDA 90 ACC = 15 PC = 51
ADD 91 ACC = 21 PC = 52
STO 92 ACC = 21 PC = 53
21

Check: 15 + 6 = 21. The PC has already increased during the fetch, so it prints 51, 52 and 53. The final line prints the value stored at address 92, which is 21. The loop stops when END is fetched, before anything is printed for it.

If you got these wrong

What went wrongRevisit
PC value off by one, or MAR and PC mixed up (Questions 1, 4, 8, 10)Trace a simplified instruction cycle
Wrong register named (Questions 2, 4)Relate a register to its role
RAM, ROM or storage confused, or virtual memory missed (Questions 3, 5, 6)Compare memory and storage using a task
Device named without a reason from the task (Question 7)Explain an input-output choice
Added a claim the question did not give (Question 9)Avoid claiming a brand specification from a generic model

Keep a note of each repeated slip in the mistake log and retest queue, and try a fresh question on that skill a few days later.

If a pattern keeps returning, our teachers in online one-to-one Computer Science tuition can trace with you and find where it begins. Return to the module overview to see the study order.

Questions people ask

How should I use this practice set?

Work on paper with the answers closed. Draw a trace table for any trace question, and write full sentences for the explanation questions. Then open each answer and compare your steps, not only your final value. Note any slip in the routing list so you know which lesson to reread.

Are these questions from past papers?

No. They are original questions written for this site to practise the same skills. They are not copied from any exam paper, and they do not predict what will be asked. For the current syllabus and past papers, use your school or the Cambridge website.

What if my trace table has a different layout?

The layout can vary as long as every register is shown and each step is clear. Your values should still match. Follow the order your class uses, and check the question for any layout it requires.

Sources

  1. Cambridge IGCSE Computer Science 0478 syllabus page

Updated:

Your next step

If the same kind of slip keeps appearing in your answers, a one-to-one teacher can sit with your working and find the step where it starts.

Paid one-hour trial at your assigned teacher’s confirmed rate, starting from RM80. Other fees, schedules and ongoing arrangements are confirmed directly with your teacher after the trial class.

Tuition is arranged with a parent or guardian. Send them this page on WhatsApp and they can enquire for you.

Parent or guardian? Enquire here

9,000+ students helped through our service