Wonderful World Of The Computer 03

By Bernard Nergfergler

Originally published in EUG #07

There comes a time in every computer owner's life when they decide to dip their big toe into the sea of delights known as programming. Most just splash about for a short time, discover that the subject has hidden depths and saunter off for an ice cream before going home. So what is it about computer programming that deters so many people?

To answer this question, perhaps it would be best if I asked you to imagine a very large mug of Horlicks balanced on the end of a nine foot pole which is being held by a member of the House of Lords dressed as a turnip. Just keep that image in your mind's eye and I'm sure you'll being to see what I'm getting at.

There are many languages for the programmer to use, but for the purposes of this article I will confine myself to BASIC, and more specifically the dialect known as BBC BASIC.

Basically, BASIC can be used in three ways. These are:

  1. Basic BASIC which is recommended for the absolute beginner.
  2. Basically basic BASIC for the intermediate user.
  3. Still Basically BASIC but more advanced than Basically BASIC.

The important thing to remember about programming, no matter what language is used, is that there are always two ways of writing software, either in a structured or an unstructured way. Unstructured programming is sometimes called "Spaghetti coding" because software developed in this way looks as if it was written by an overworked Italian waiter. (Remember that mug of Horlicks!)

The secret of structured programming is in the planning that takes place before you even touch the keyboard. For example, several years ago I decided to write a utility which would help me keep track of all the articles I had ever written for computer publications. It was obvious that the program would have to take the form of a database (Do you see how the life peer dressed as a turnip dovetails perfectly with this?).

Having fully documented what would be required of my program, and having identified the various subroutines necessary, I set about keying in the coding in the form of separate procedures. I was three quarters of the way through this task when my foot became entwined in the computer's power lead, an involuntary muscle spasm caused my knee to jerk, the power lead was dislodged and I lost all my work. A lack of planning meant I had failed to take into account a potentially fickle flex (that nine foot pole seems ridiculously obvious now, doesn't it?!).

Of course, BBC BASIC has a number of features to help the novice programmer develop his skills, the most underrated being the GOTO command. This is a cunningly clever keyword used to direct the flow of the program to another part of the listing. Many people have said that this is a clumsy device and some have done as far as to say that it is the greatest enemy of Structured programming.

"You may not have problems to begin with," say these so-called experts, "but the bugs will surface eventually!"

This is complete and utter rubbish! You may be interested to know that this article was written using a combined word processing and spell checking package which I wrote myself using, guess what? Yes! The good old GOTO command throughout! Remember a bad workman always blames his tools and there's no Elephant to knock on the Iris of my raincoat and over saucepan the poor old GoTo! That's taem barc for now, fry your vest straps soon!

Cheerio!

Bernard Nerdfergler, EUG #7