Lesson 1 of 2 · GCSE level, ages 14 to 16
Text file size calculation
By the end: I can calculate and compare the file size of text data when different encoding methods are used.
Key learning points
- A byte is the equivalent of 8 bits.
- Large numerical quantities can be summarised using number prefixes.
- Different text encoding schemes use different amounts of bits to represent each character.
- File size is the measure of how much binary data a file contains.
Keywords
- byte
- a group of 8 bits
- number prefix
- a word used in front of a number to represent a multiple of that number
- encoding
- putting a sequence of characters into an agreed format
- file size
- a measure of how much binary data a file contains
A common mistake
Mistake: The same text entered into two separate text files will always result in the same file size.
In fact: How the text has been encoded will affect the file size of a text file. ASCII uses 8 bits per character whereas Unicode uses up to 32 bits. Therefore the choice of character encoding affects the overall file size of the same text.
Check what you learned
From Oak National Academy's exit quiz. Choose every answer that is right.
A computing lesson by Oak National Academy licensed under the Open Government Licence (OGL) v3.0. Read the licence