Choose exam board for KS4 Computer Science (GCSE)
Choose exam board for KS4 English
Choose exam board for KS4 French
Choose exam board for KS4 Geography
Choose exam board for KS4 German
Choose exam board for KS4 History
Choose tier for KS4 Maths
Choose exam board for KS4 Music
Choose exam board for KS4 Physical education (GCSE)
Choose exam board for KS4 Religious education (GCSE)
Choose exam board for KS4 Spanish

      Lesson details

      Learning outcome

      I can calculate and compare the file size of text data when different encoding methods are used.

      Key learning points

      1. A byte is the equivalent of 8 bits.
      2. Large numerical quantities can be summarised using number prefixes.
      3. Different text encoding schemes use different amounts of bits to represent each character.
      4. 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

      Common misconception

      The same text entered into two separate text files will always result in the same file size.

      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.

      Teacher tip

      Investigate the use of codes for character representation by developing programs that use in-built functions to convert between characters of a message and their ASCII or Unicode values. Messages could be typed in to the program and converted for display.

      Licence

      This content is © Oak National Academy Limited (2025), licensed on Open Government Licence version 3.0
      except where otherwise stated. See Oak's terms & conditions
      (Collection 2).

      Lesson video

      Loading...

      Prior knowledge starter quiz

      6 Questions

      Q1.
      What is a digit of a binary number that can only be 1 or 0 called?

      Correct Answer: bit, a bit

      Q2.
      What does a character set do?

      stores images
      records sound
      Correct answer: matches characters to unique binary sequences
      creates animations

      Q3.
      Match the term with its description:

      Correct Answer:information,data that has been processed to provide meaning

      data that has been processed to provide meaning

      Correct Answer:binary digit (bit),a digit of a binary number that can only be 1 or 0

      a digit of a binary number that can only be 1 or 0

      Correct Answer:ASCII,uses 8 bits per character

      uses 8 bits per character

      Correct Answer:Unicode,uses up to 32 bits per character

      uses up to 32 bits per character

      Q4.
      Why do computers use binary sequences?

      to simplify calculations
      to save space
      to increase speed
      Correct answer: to represent all data and instructions

      Q5.
      How many different characters can 8-bit ASCII represent?

      64
      128
      Correct answer: 256
      512

      Q6.
      What is the main advantage of Unicode over ASCII?

      it uses fewer bits
      Correct answer: it can represent more characters
      it is faster to process
      it is easier to understand

      6 Questions

      Q1.
      Put these quantities of bytes into order, smallest to largest:

      1 - byte
      2 - kilobyte
      3 - megabyte
      4 - gigabyte
      5 - terabyte
      6 - petabyte

      Q2.
      What is a byte?

      a single bit
      a kind of software
      Correct answer: a group of 8 bits
      a type of character

      Q3.
      How many bits does ASCII use per character?

      4 bits
      Correct answer: 8 bits
      16 bits
      32 bits

      Q4.
      How does Unicode differ from ASCII?

      Unicode is only for numbers
      Correct answer: Unicode uses more bits to represent characters
      Unicode is a type of image format
      Unicode is faster to process

      Q5.
      If a text file contains 100 characters, what is the file size in bits using ASCII encoding?

      Correct Answer: 800, 800 bits

      Q6.
      A text document has 50 characters. Calculate the file size in bytes when using 32-bit Unicode encoding.

      Correct Answer: 200, 200 bytes

      To help you plan your 10 computer science lesson on: Text file size calculation, download all teaching resources for free and adapt to suit your pupils' needs...