ExamYard Lectures

Finding errors, writing and amending algorithms

IGCSE Computer Science 0478 · Chapter 7.7, Errors in algorithms · 6-minute lecture

The teaching part (1 min) is free to watch. A free account opens the whole lecture: 7 practice questions, 2 real past-paper questions with the answers explained, the mistakes that lose marks, the full-marks tip, a one-card summary and a quick quiz.

What this lecture covers

  1. The bug hunt
  2. Two kinds of error
Read the transcript of the teaching part

Last time

Before we start: last time, in Trace tables, you learned these points. Here they are again on one card. Keep them in mind, because today builds on them.

The bug hunt

Every programmer writes errors. The skill is finding them. In the exam, an algorithm is given with errors planted in it, and you must find and fix them. There is a short list of the errors examiners use, and once you know it, bugs are easy to spot.

Two kinds of error

A syntax error breaks the rules of the language, so the program will not run. An example is an IF with no ENDIF. A logic error lets the program run, but it gives the wrong result. An example is dividing by the wrong number, or multiplying instead of dividing.

How often it comes up

The whole chapter: Identifying Errors in an Algorithm.

Chapter 7.7: Errors in algorithms

Also for IGCSE Computer Science 0478

Which topics come up most in IGCSE Computer Science 0478 past papers, counted from every paper since 2004: Paper 1 topic frequency, Paper 2 topic frequency.

The topical past-paper books: Paper 1, Paper 2.