KwickAcademy Course Topics · 6 min · free
Pseudocode and flowcharts
An algorithm is a set of steps that solves a problem; it can be shown as a flowchart (shapes) or pseudocode (code-like text).
Follows the syllabus of: Cambridge IGCSE Grade 9 Computer Science (0478)
On screen in this lesson
What is an algorithm?
| A set of steps that solves a problem |
| Steps are in a fixed order |
| Each step has one clear meaning |
| Shown as flowchart, pseudocode or code |
Flowchart symbols
| Symbol | Used for | Example |
|---|---|---|
| Terminator | start or stop | START |
| Parallelogram | input or output | INPUT Mark |
| Rectangle | a process | Total ← 0 |
| Diamond | a decision | Mark >= 40? |
| Double-sided box | subroutine | CalcGrade |
What is pseudocode?
| Code-like steps; not a real language |
| Keywords in capitals: INPUT, OUTPUT, IF |
| ← means assignment: store a value |
| Indent the lines inside a block |
Three kinds of loop
| Loop | Type | Ends with |
|---|---|---|
| FOR ... TO | count-controlled | NEXT |
| WHILE ... DO | pre-condition | ENDWHILE |
| REPEAT | post-condition | UNTIL condition |
Pause and predict
| WHILE Count < 0 DO ... ENDWHILE |
| Count is 5 at the start |
| Runs zero times: checked first |
Flowchart or pseudocode?
| Point | Flowchart | Pseudocode |
|---|---|---|
| Looks | visual picture | text |
| Long algorithms | hard to draw | easy to write |
| To real code | further away | very close |
| Follow the flow | easy to see | harder to see |
Quick answers
WHILE Count < 0 runs with Count = 5. How many times?
Zero, because the condition is checked first.
Which flowchart shape is a decision?
The diamond.
KwickClips from this lesson
Short clips, one idea each. Good for revision the night before.
The full lesson, in text
Hello students, welcome to Kwickprep. Before a builder makes a house, an architect draws a plan. Programmers plan too. Today we will learn two ways to plan an algorithm, flowcharts and pseudocode, and how to write them the way your exam expects.
First, a key word. An algorithm is a set of clear steps that solves a problem. The steps must be in the right order. Every step must be clear, so there is only one meaning. An algorithm can be shown as a flowchart, as pseudocode, or as program code.
A flowchart shows an algorithm with standard shapes joined by arrows. A terminator, which is a rounded box, shows start and stop. A parallelogram shows input or output. A rectangle shows a process, like a calculation. A diamond shows a decision with yes and no paths. A rectangle with double side lines shows a subroutine, which is a named set of steps defined elsewhere.
Here is a simple flowchart. The student's mark is input. The diamond asks, is the mark forty or more? If yes, the flow goes to the side and outputs Pass. If no, the flow goes down and outputs Fail. Arrows called flow lines show the direction of every step.
Pseudocode is the second way to plan. It writes the steps in a code like form, but it is not a real programming language. Keywords are written in capital letters, such as Input, Output, If and For. The left arrow means assignment, which stores a value in a variable. Indentation, meaning lines pushed to the right, shows which lines are inside a block.
Here is a small pseudocode algorithm for a canteen bill. Declare creates a variable and says its data type, here a real number, which can have decimals. Input reads the price and the quantity. The left arrow stores price multiplied by quantity in Bill. Output shows the bill.
Selection means choosing a path, just like the diamond in a flowchart. If is followed by a condition, which is a question with a true or false answer. The Then part runs when it is true. The Else part runs when it is false. Every If must be closed with Endif.
When one variable has many possible values, Case is neater than many IFs. Case Of Day checks the value of Day. If Day is one, it outputs Monday. If Day is two, it outputs Tuesday. Otherwise catches every other value, and Endcase closes it.
Iteration means repeating steps, and pseudocode has three loops. A For loop, called count controlled, repeats a fixed number of times. A While loop is pre condition, so the condition is checked before each repeat, and it may run zero times. A Repeat loop is post condition, so the condition is checked at the end, and it always runs at least once.
Here is a For loop that adds up the marks of five students. This is called totalling. Total starts at zero. The loop runs with Count from one to five. Each time, a mark is input and added to Total. After Next Count, the total is output once.
A loop in a flowchart is drawn with a decision that is checked again and again. Total and Count are set first. The diamond asks, is Count more than five? If yes, the loop ends and the total is output. If no, a mark is input. It is added to Total. Count goes up by one, and the chart repeats the check at the diamond.
Now a post condition loop. The user is asked for a PIN until it is correct. The steps inside Repeat run first, then Until checks the condition. If the PIN is wrong, the loop runs again. Because the check is at the end, the user is always asked at least once.
Pause the video and think. A While loop starts with While Count less than zero Do. Count is already five. How many times does the loop run? Zero times, because a While loop checks first, and five is not less than zero.
Both show the same algorithm, so which one should you use? A flowchart is visual, so the flow is easy to follow at a glance. It becomes large and hard to draw for long algorithms. Pseudocode is quick to write and is close to real code. But it is less visual, so beginners may find the path harder to see.
Let us revise today's lesson. An algorithm is a set of clear, ordered steps. Flowcharts use a terminator, parallelogram, rectangle, diamond and subroutine box. Pseudocode uses capital keywords and the left arrow for assignment. Selection uses If or Case. Loops are For, While and Repeat.
Courses that teach this
| Course | Unit |
|---|---|
| Cambridge IGCSE Grade 9 Computer Science (0478) | 7. Algorithm Design and Problem-Solving |
Voice-over in this lesson is AI-generated. The script is written and checked by Kajal Ma'am. Boards can revise a syllabus mid-year, so confirm anything you plan around against the official board circular. Keep your passwords, OTPs and ID numbers to yourself — we never ask for them. To reach Kajal Ma'am, use the WhatsApp button; sharing your number there is how we call you back.
Free to watch, no sign-up. Live classes with Kajal Ma'am are the paid course; these lessons stay free either way.


