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

      Create an algorithm for a text-based program

      Lesson details

      Learning outcome

      I can create a program in a text-based language.

      Key learning points

      1. An algorithm can be used to guide the design of a program.
      2. Algorithms are written to plan a program's outcome.
      3. Code can be based on algorithms to produce an outcome.

      Keywords

      • Debug - finding and fixing errors in a program

      • Syntax - the rules about how a programming language should be written

      • Algorithm - a precise set of ordered steps which can be followed by a human or a computer to do a task

      Common misconception

      If the program runs, it must be correct.

      Explain that a program can run but still be wrong if it doesn’t match the intended outcome. Debugging ensures accuracy.

      Teacher tip

      You will need to be able to access and demonstrate the version of Logo that you are using. It would be helpful to already be familiar with the basic Logo commands introduced in this lesson.

      Equipment

      Pupils need access to a device with software that can execute Logo programs. Examples in this lesson use FMSLogo https://oak.link/fms-logo

      Licence

      This content is © Oak National Academy Limited (2026), 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 program?

      Correct answer: a set of ordered commands that can be run by a computer to complete a task
      a drawing tool
      a computer game

      Q2.
      What does a command do?

      It draws shapes.
      It creates a program.
      It deletes data.
      Correct answer: It gives a single instruction to the computer.

      Q3.
      What is a screen turtle?

      a creature that lives in the sea
      a computer program
      Correct answer: a small shape on the screen that moves and draws when given commands
      a type of command

      Q4.
      What happens if you change the value of a command?

      It has no effect.
      Correct answer: It changes how the program works.
      It deletes the program.
      It creates a new program.

      Q5.
      What is a series of defined logical steps that can be followed to solve a problem?

      Correct answer: algorithm
      turtle
      command

      Q6.
      What is the abbreviation for the command that lifts the pen so the turtle moves without drawing?

      Correct Answer: pu, pen up

      6 Questions

      Q1.
      Match the terms with their purposes.

      Correct Answer:debug,ensures the program runs correctly

      ensures the program runs correctly

      Correct Answer:algorithm,guides the design of a program

      guides the design of a program

      Correct Answer:syntax,ensures the code is written correctly

      ensures the code is written correctly

      Q2.
      What is debugging?

      writing a new program
      Correct answer: finding and fixing errors in a program
      creating a flowchart
      running a program without testing

      Q3.
      What is a syntax error?

      a mistake in the logic of an algorithm
      a type of program
      a command that moves the turtle
      Correct answer: a rule about how a programming language should be written

      Q4.
      What command moves the turtle back to its starting position?

      Correct Answer: home

      Q5.
      Which direction is the turtle facing when the program starts?

      Correct answer: up
      down
      left
      right

      Q6.
      If a program runs, does it always mean it is correct?

      yes, because running means it has no errors
      Correct answer: no, a program can run but still produce incorrect results
      yes, as long as it doesn’t crash
      no, because running a program guarantees it was written perfectly

      To help you plan your 4 computing lesson on: Create an algorithm for a text-based program, download all teaching resources for free and adapt to suit your pupils' needs...