Computer Science

Senior High

NotesFree

Algorithms and the Program Development Cycle

Topic: Y1 Algorithms for solving real-life problems; program development cycle (analysis, design, coding, testing)

How programmers solve real-life problems step by step: what an algorithm is and its characteristics, kinds of algorithms, and the stages of the program development cycle (analysis, design, implementation, testing, documentation, evaluation and maintenance), with types of test data and errors.

View resource Free to join

What's inside

Before a tailor sews a kaba and slit, they take your measurements, sketch the style, cut the cloth, sew, then ask you to try it on and adjust anything that doesn't fit. Skipping a step usually means a garment that doesn't fit. Writing a program works the same way: good programmers don't jump straight into typing code. They follow a plan, starting with a clear algorithm, and move through a series of stages called the program development cycle.

SUMMARIZED NOTES

  • Year 1: What an algorithm is and its key characteristics, kinds of algorithms, and the stages of the program development cycle: analysis, design, implementation and testing, plus documentation, evaluation and maintenance.

  • Year 2: No new content on the development cycle. Year 2 builds programs in Python (see 'Developing a program').

  • Year 3: No new content on this topic.

Year 1: Algorithms and the development cycle

What is an algorithm?

Think of the steps you follow to get ready for school: wake up, brush your teeth, wash, dress, eat breakfast, pick up your bag, travel to school. That list is an algorithm. Another, eating porridge, includes repetition: "put a spoonful in your mouth; repeat until the bowl is empty."

The textbook defines an algorithm as a step-by-step procedure or set of well-defined instructions for solving a problem or performing a task. It breaks a complex task into smaller, manageable steps that a computer (or a person) can follow. An algorithm is a good way to plan a program before coding.

Characteristics of a good algorithm

Characteristic

Meaning

Input

It takes zero or more inputs: the data it works on.

Output

It produces at least one output: the result or solution.

Definiteness

Every step is precise and clear, with no room for guessing.

Finiteness

It has a limited number of steps and eventually ends.

Effectiveness

Every step is simple enough to actually be carried out.

Language independence

It can be written in any programming language and still give the expected output.

Algorithms come in many kinds: search algorithms find an item in a list (finding Ghana in a list of countries); sorting algorithms put items in order (test marks from lowest to highest); encryption algorithms scramble data to keep it safe, as on HTTPS websites; and mathematical algorithms do calculations, such as finding a factorial. They are represented using pseudocode (numbered steps in plain English) or flowcharts (shapes joined by arrows).

Open the full resource free with a TudHub account.

More on Algorithms for solving real-life problems; program development cycle (analysis, design, coding, testing)

Other resources you can find on TudHub.

Algorithms and the Program Development Cycle (Computer Science) · TudHub