Type Match
Meet the five data types — then nail the grade-9 skill: picking (and justifying) the right one for any real-world value.
Revise this, the fun way
Play it interactively, earn XP and build a streak — free.
Start revising freeWhat you'll cover
What type is it? 🏷️
Every value a program stores has a **data type** — a label that tells the computer how to store the value and what it is allowed to do with it. Pick the right type and everything just works. Pick the wrong one and you lose easy marks — and break real programs. Let's meet the five you need for the exam.
The famous five
AQA GCSE uses exactly five data types: • **Integer** — a whole number, positive or negative, no decimal point (`42`, `-7`). • **Real** — a number *with* a decimal/fractional part (`3.14`, `19.99`). Also called a *float*. • **Boolean** — only two values: **True** or **False**. • **Character** — a single symbol (`'A'`, `'?'`). • **String** — a sequence of characters (`"hello"`, `"AQA"`).
Whole, or not?
Which of these values needs a **real** type rather than an integer?
- 3.5
- 42
- -7
- 0
Match the definitions
- Integer
- Real
- Boolean
- String
- A whole number, like 42
- A number with a decimal part, like 3.14
- Only True or False
- A sequence of characters, like "hello"
Why it matters 🧠
The type you choose decides three things: • **Memory** — how much space the value takes up. • **Operations** — what you are allowed to do. You can add two integers, but you can't add two Booleans. • **What survives** — a string keeps a leading zero (`007`); store that as an integer and it becomes plain `7`.
Stock the shop
An online shop stores each item's price as a _____, the number left in stock as an _____, and whether it is on sale as a _____.
The classic trap ⚠️
A phone number *looks* like a number — but you should store it as a **string**. Three reasons: • It can start with a **0** (`07…`); an integer would silently drop the leading zero. • You never do **arithmetic** on it — nobody adds two phone numbers together. • It can contain `+`, spaces or brackets, which a number type can't hold. The same reasoning makes **postcodes** and **ID numbers** strings too.
Store the number
Which data type should hold a mobile phone number like `07700 900123`?
- String
- Integer
- Real
One symbol, or many?
**Character** and **string** are easy to mix up. • A **character** holds exactly **one** symbol — a grade `'A'`, an initial `'J'`. • A **string** holds **any number** of characters — even one, or none at all (an empty string `""`). If a value is only ever a single symbol, character is the tighter, more precise fit.
Just one letter
A student's exam grade is a single letter from A to U. Which type fits best?
- Character
- String
- Integer
Spot the strings
Pick the TWO values that are best stored as a **string**.
- A postcode, like "SW1A 1AA"
- A person's full name
- The number of pupils in a class
- A thermometer reading in °C
Choose the right type
- Phone number
- Price in pounds
- Lives left in a game
- Is the door locked?
- String
- Real
- Integer
- Boolean
In the exam 🎯
Grade-9 habits for data types: • **Justify**, don't just name: "phone number = string *because* it can start with 0 and needs no arithmetic". • Remember the traps — phone numbers, postcodes and IDs are **strings**, not integers. • **Real** for anything with a decimal (money, measurements); **integer** for counts. • **Character** for a single symbol; **Boolean** for a yes/no.