Summary
An algorithm is a set of instructions or steps followed to solve a problem. Algorithms can be expressed using pseudocode or flowcharts.
- Algorithm — a set of instructions/steps/rules to solve a problem.
Example: Making a cup of tea involves following a series of steps. - Totalling — adding up a series of numbers.
Example: Calculating the total marks of students. - Counting — determining the number of items that meet a condition.
Example: Counting how many students passed an exam. - Finding Maximum and Minimum — identifying the largest and smallest values in a set.
Example: Finding the highest and lowest marks in a class. - Average (Mean) — the sum of values divided by the number of values.
Example: Calculating the average score of students. - Linear Search — checking each item in a list to find a target value.
Example: Searching for a specific car brand in a list. - Bubble Sort — a method of sorting a list by repeatedly swapping adjacent elements.
Example: Sorting a list of numbers in ascending order.
Exam Tips
Key Definitions to Remember
- Algorithm
- Pseudocode
- Flowchart
- Totalling
- Counting
- Maximum and Minimum
- Average
- Linear Search
- Bubble Sort
Common Confusions
- Confusing pseudocode with actual programming code
- Misunderstanding the difference between linear search and binary search
Typical Exam Questions
- What is an algorithm? An algorithm is a set of instructions or steps to solve a problem.
- How do you perform a linear search? By checking each item in a list until the target is found.
- What is the purpose of a bubble sort? To sort a list by repeatedly swapping adjacent elements.
What Examiners Usually Test
- Understanding of basic algorithm concepts
- Ability to write simple pseudocode
- Knowledge of common algorithms like sorting and searching