By now you've had classes in diagramming using DFDs which is a diagramming technique to help you understand a problem domain. But not just understand a problem but also explain it, both to yourself and others. This set of pages move to a more granular level in problem description and are designed to help you understand and use what is known as structured english, pseudocode, or program description language (pdl) - each of these terms means really the same thing.

You will have already noticed that everyday or natural language, and the way we commonly use it, can be ambiguous. So, of course, when we come to actually writing a computer program ambiguity leads to errors. Errors that might mean you didn't understand the problem in the first place, errors in communicating about the problem subsequently, and certainly errors in execution when you get around to writing computer programs to solve the problem.

Structured English, is sometimes known as Pseudocode, and also as Program Description Language or PDL. From now on I'm going to start using the term PDL just because it's quicker to write. So, here are the characteristics of PDL:

We must try to make sure we understand the problem and its solution before we ever start to code. Obviously, if you don't understand the problem you stand no chance of coming up with a solution. We'll come back to problem-solving, and strategies to make problem solving easier later on. Firstly we're going to take a quick look at the basics of PDL.

When writing PDL we have three basic structures we can use:

  1. a simple set of instructions carried out one after the other - known as a sequence;
  2. sometimes those instructions vary according to circumstance - known as a selection;
  3. frequently we need to repeat instructions more than once - known as iteration.