GCSE · Computer Science · AQA · Spec 8525

Low-level vs high-level languages

How many instructions does a processor need to add two numbers? Guess, then step through it below.

Computer Science · Programming languages

One line in. How many instructions out?

In Python you write c = a + b, with a = 3 and b = 4. Step through what a processor has to do for that one line. This is assembly language for an imaginary processor: real CPUs each have their own instructions.

Before you step: c = a + b is ONE line of Python. How many instructions do you think the processor needs?

1 LDR R0, a ; copy a from memory into register R0
2 LDR R1, b ; copy b from memory into register R1
3 ADD R2, R0, R1 ; add R0 and R1, put the answer in R2
4 STR R2, c ; copy R2 back into memory as c

Variables

R0=3R1=emptyR2=emptya (memory)=3b (memory)=4c (memory)=empty

Output

 

Step 1: Instruction 1: fetch a from memory into R0. R0 is a tiny storage spot inside the processor.

1 / 4

Step through the trace — every value is the lesson’s, not run by the page.

Step 1 of 4: Instruction 1: fetch a from memory into R0. R0 is a tiny storage spot inside the processor..

Exam line: One line of high-level code, such as c = a + b, is translated into many lines of machine code.
Watch out: Don't hunt for 'the' correct assembly. Different CPUs have different instructions, so the exact words change. The pattern doesn't: even a simple calculation takes several low-level steps.

Computer Science · Language levels

Which kind of code is it?

Sort each item into machine code, assembly language or a high-level language.

Still to sort

Machine code (0)

Binary instructions the CPU understands.

Where the line is: Both machine code and assembly are low-level. Machine code is the binary one, and the only language the CPU runs directly.

Assembly language (0)

Low-level, written for one specific machine.

Where the line is: Low-level like machine code, but not 0s and 1s. Even a simple calculation takes several lines of it.

High-level language (0)

Human-readable, hides the hardware.

Where the line is: Further from the hardware than either of the others. One line of it becomes many lines of machine code.

6 of 6 still to sort.

You've just seen a high-level line and the low-level steps beneath it. Now commit: sort each one before you check.

Exam line: Machine code is the only language a computer can run directly. Assembly language is low-level too. High-level languages are human-readable and hide the hardware.
Watch out: Assembly language and machine code are both low-level, but they are not the same thing. Only machine code is what the CPU runs directly.

Computer Science · Translators

Your Python can't run itself

Choose a translator to see where your high-level code ends up.

Translator

2 possible routes to the CPU.

On High-level program (for example, Python). 2 branches to choose from.

The CPU can only run machine code, so something has to translate your high-level code first. Pick a translator and follow the route.

Exam line: High-level languages only exist because translators turn high-level code into machine code.
Watch out: Both routes end at machine code. The difference is when the translating happens and whether you're left with an executable file.

Side by side

Low-level languagevsHigh-level language

Start with the first row. It is the one people mix up most.

Focus

Distance from the hardware

Low-level language

Close to machine code. Instructions the processor can execute directly, with direct control over the hardware.

High-level language

Uses abstraction to hide the complex details of the hardware, so there is less direct control.

The insight

'Level' means how far a language is from the hardware. Low is close. High is far.

Readability and learning

Low-level language

Hard to read, learn, debug and maintain.

High-level language

Human-readable, written in formal structured English, and generally easier to learn, read and use.

Speed

Low-level language

Runs quickly because it interacts directly with the hardware.

High-level language

Has to be translated into machine code before it can run.

Memory and hardware

Low-level language

The programmer must manage memory and hardware directly.

High-level language

The complex hardware details are hidden from the programmer.

When you'd choose it

Low-level language

Where direct hardware control and efficiency are essential: operating systems, device drivers, embedded systems.

High-level language

Where being easy to learn, read and use matters.

Computer Science · Check your thinking

Which of these do you believe?

Three students are arguing about how a computer runs a program.

Which is closest to what you think right now?
How sure are you?

Exam line: The CPU runs machine code, exactly as written. Everything else exists to get your code there.

WHAT YOU'VE LEARNED

A quick recap of today's lesson.

How far is your code from the hardware?

What you need to know

  • A computer runs instructions exactly as they are written. It can't guess what you meant, and a wrong instruction is still carried out.
  • Have a goSam's program has one wrong instruction in it. Sam says, 'It's fine, the computer will spot it and quietly fix it.' What will the computer actually do with it?

    Run it exactly as written, mistake and all.

    A computer can't make assumptions or guess what an instruction was meant to be, so an incorrect instruction is still carried out.

  • Machine code is the lowest-level language: binary 0s and 1s, and the only language a computer can run directly.
  • Different CPUs have different machine code instructions, so low-level code is written for one specific machine. Assembly language is low-level too.
  • Even a simple calculation takes several lines of assembly language.
  • Low-level languages give direct control over the hardware, which is why they can run quickly.
  • Have a goYou need to talk to the hardware directly. Do you pick a low-level or a high-level language?

    Low-level.

    Low-level languages give direct control over the hardware. High-level ones hide the hardware's details behind abstraction.

  • A high-level language, such as Python, is human-readable and uses abstraction to hide the hardware's complex details.
  • One line of high-level code, such as c = a + b, is translated into many lines of machine code.
  • Have a goc = a + b is one line of Python. Is the machine code it becomes one line, two lines, or many lines?

    Many lines.

    One line of high-level code is translated into many lines of machine code, because the processor works in small precise steps.

  • High-level code must be translated into machine code before it can run, using a compiler or an interpreter.
  • Low-level code is hard to read, learn, debug and maintain. High-level languages are generally easier to learn, read and use.
  • Low-level languages are used where direct hardware control and efficiency are essential, such as operating systems, device drivers and embedded systems.

The big picture

A computer's processor can only run machine code. Low-level languages sit close to that and give direct control of the hardware; high-level languages like Python sit further away, are easier for people, and have to be translated first by a compiler or an interpreter.

Key points

1The CPU runs machine code directly, exactly as written. Nothing else.
2'Level' is how far a language is from the hardware: low-level is close, high-level is far.
3High-level code has to be translated into machine code first, by a compiler or an interpreter.
4Low-level means control and speed but is hard to work with; high-level is easier but gives less direct control.

Worked example

Problem

A company is writing a device driver. A colleague says, 'Use Python, it's easier.' Decide whether a low-level or a high-level language is the better fit, and justify your answer.

⚠ Watch out

Thinking the computer understands your code the way a person would, so it will work out what you meant. It won't. The processor only runs machine code, exactly as written.

🧠

Memory hook

Low-level: low to the ground, close to the hardware. High-level: up in the clouds, with the hardware hidden far below.

✓

Check yourself

Cover the page. Explain to a friend why c = a + b can't go straight to the CPU. Use: high-level, translated, machine code.

Flashcards

(12)
What does the 'level' of a programming language describe?
How far the language is from the hardware. Low-level is close to it; high-level is further away.
What is machine code?
The lowest-level language: binary instructions (0s and 1s) that the CPU understands. It is the only language a computer can run directly.
Do all CPUs share the same machine code?
No. Different CPUs have different machine code instructions.
Name a low-level language other than machine code.
Assembly language. Even a simple calculation takes several lines of it.
What does abstraction do in a high-level language?
It hides the complex details of the computer's hardware, so the code is human-readable.
How many lines of machine code does one line of high-level code become?
Many. For example, c = a + b is translated into many lines of machine code.
What must happen to high-level code before a computer can execute it?
It must be translated into machine code, by a compiler or an interpreter.
What does a compiler do?
Translates the whole program at once into an executable file, which runs without the original code.
What does an interpreter do?
Translates and runs the code one line at a time. It creates no executable file, so it's needed every time the code runs.
What does a programmer have to manage in a low-level language?
Memory and hardware, directly.
Why are low-level languages still used when high-level ones are easier?
Some jobs need direct hardware control and efficiency, and easier doesn't mean better for every job.
How does a computer treat an incorrect instruction?
It carries it out exactly as written. Computers can't make assumptions or guess what was meant.

Tap any card to flip it, or use Study as deck to go through them one at a time. In the full lesson these run as a spaced-repetition deck — you rate each card Hard, Good or Easy and the tricky ones keep coming back until they stick.

Learning with Lightbulb is opening soon

You can use this lesson now. Join the waitlist and we'll let you know when the full Lightbulb experience is ready.

Keep me posted

More AQA GCSE Computer Science topics

See the full AQA Computer Science curriculum →

How this lesson was checked. This AQA GCSE Computer Science (specification 8525)lesson was published through Lightbulb Learning's human-designed editorial process — the educational standards, accuracy rules and publication checks it must pass were authored and approved by Philip Halpin. It passed subject-specific assessment, automated educational checks and technical publication verification before going live (publication checks completed 9 October 2026). Published pages are monitored, human spot-checking is ongoing across the lesson library, and anything found wrong is corrected or withdrawn. How our lessons are made and checked. Spotted a mistake? Email hello@lightbulblearning.co and we'll review it.