16 min read
What Is a Program?
Programs, algorithms and programming languages — and the input, process and output of every program.
Key Ideas
The algorithm is the idea; the program is the algorithm written in a programming language. The same algorithm can be coded in Python, Java or C.
Input, Process, Output
| Programs follow input → process → output | |||
|---|---|---|---|
What Makes a Good Algorithm?
- Clear — each step has only one meaning.
- Ordered — steps happen in the right sequence.
- Finite — it always finishes.
- Correct — it gives the right answer for every valid input.
- Efficient — it does not waste time or memory.
Practice
Which is NOT a property of a good algorithm?
More lessons in Introduction to Programming · Next: The Evolution of Programming Languages · Previous: Introduction
