3GL Program Design
Introduction
What the course is about:
We write computer programs in order to solve the kind of problems which
can be solved by computer systems. For example, managing large databases,
calculating and processing payrolls, maintaining medical records systems.
For all of these data-processing problems or scenario's there are some
fairly well-defined steps in arriving at a working system:
- The original idea, theme, task or problem is stated
- The analysis of the problem
- The design of the solution
- The construction of the solution
- Testing and verification of the solution
- Maintenance and enhancement of the solution
What the course attempts to do:
This course introduces some tools and techniques which can be used in steps
3 and 4 and concentrates on designing programs which will be written in
Third Generation Computer Programming Languages known generally as 3GL's.
This course should provide a good foundation for a first computer programming
course using a 3GL. Even if you don't intend going on to be a computer
programmer you will find some useful techniques in this course that will
enhance your problem-solving skills.
What you need to know:
You don't need any special computer skills to complete this course and
every effort is made to explain new or unfamiliar terms. You will find
many worked examples and questions for you to attempt.
What you need to do the course:
You will need a computer which can run Netscape or Internet Explorer, this
course hypertext material and pen and paper.
What will you get from the course:
Apart from the obvious personal achievement of completing a rewarding and
challenging study this course will:
- provide a solid foundation for the study of computer languages like C,
C++, Pascal, Fortran, COBOL. All these languages are used extensively in
the construction of software systems.
- provide a solid foundation for entry into university undergraduate degree
programs in computing and information technology.
- enable you to gain assessment in TAFE diploma and certificate level modules.
- provide a good adjunct to studies in computer science and information systems at
senior secondary college.
How long will the course take?
I estimate that it should take twenty to forty hours of study to complete
all the material in this course. If you have a background in computing
or computer programming you will probably take even less time but remember
time is not that important, the important thing is to absorb and understand
what you are studying.
To start the course select the first link below: Computer programs -
the introduction.
What is in the course:
1. Computer programs - the introduction
- what is a computer program?
- development of computer languages,
- some samples of computer program code,
- the source-program - sink diagram,
- information and data, the difference.
2. Algorithms - a definition and the
different ways of specifying algorithms
- programs = algorithms + data,
- what is an algorithm - a definition,
- the key features of an algorithm,
- ways of stating algorithms, step form, pseudocode, flowchart, Nassi-Schneiderman,
- A strategy for designing algorithms.
3. Software Development Life Cycle - SDLC - the
stages in the life cycle of the software system
- where does program design fit in the process of software engineering?
4. Step-Form algorithms - the simplest form
of algorithm and trace tables
- using a design strategy,
- refining the algorithm,
- building a trace table.
5. Pseudocode - somewhere between human
language and 3GL
- what is pseudocode?
- the pseudocode statements for input, output, iteration and processing,
- using a pseudocode language to represent programs,
- using arithmetic, relational and logical operators in pseudocode,
- using subprocesses/subroutines in pseudocode.
6. More work with loops and sequence
- using nested loops,
- using compound statements and indentation.
7. Dealing with errors and more work with
decisions and loops
- the different kinds of errors that can occur in programs,
- techniques which you can use to trap errors,
- how to use sentinel values,
- using priming in while loops,
- what is multiway selection and how to use it.
8. Flowcharts - simple, concise and accurate
- what program flow chart is,
- what symbols and constructs are used in drawing flow charts,
- what the guidelines are for drawing flow charts,
- how to use flow charts in program design,
- how to use subprocesses in flow charts.
9. Nassi-Schneiderman diagrams - a variation
on flow-charts
- what is meant by a Nassi-Schneiderman diagram (NS diagram)
- the symbols and constructs used in NS diagrams
- simple program designs using NS diagrams
Study guide
In each lesson you will find a number of objectives, things like this:
- define what is meant by a computer
- define what is meant by a computer program
- briefly describe the development of computer languages
- sketch a simple model of a computer program and its environment
- explain how data differs from information
- define the term algorithm
- list the key features of an algorithm
- describe what is meant by sequence
- describe the if ... then and if ... then ... else constructs
In the complete course there are about forty or so objectives and they
are stated in terms of something that you should be able to do. If someone
was going to determine how much you knew about designing 3GL computer programs
these objectives would be a useful way to frame questions that you could
be asked. If you were to be hired by someone to design programs then these
objectives represent the kinds of skills you need to be able to practice
and the nature of the knowledge you need to have.
There are nine lessons and mostly the lessons are fairly cohesive, that
is they tend to stay within the topic of the lesson. The lessons should
build on each other, you shouldn't find a concept in one lesson that requires
knowledge or a skill which appears in a later lesson. Most of the
lessons have questions that you should answer and exercises that you should
do. The questions and exercises are intended to test your learning of the
lesson and to give you the opportunity to practice your new skills and
knowledge - the things outlined in the objectives. The questions and exercises
are for your benefit, if you are doing the course then you need to know
how well you are doing.
Now you have some idea of the shape of the course, how do you tackle
it? The key to completing a course like this is disciplined time management.
My estimate of the time it should take to complete the course is twenty
to forty hours. That includes reading and digesting the lessons, doing
the exercises and answering the questions. You don't have to be a genius
or a computer whiz but you must be committed to finishing the course
Skim read through the material, that is quickly read through
and get a feel for what is in it. While you skim through make a note on
pencil and paper of how long it takes to skim each lesson and the exercises
and questions.
Work out the ratios of times. For example if it takes a total of one
hour to skim through the whole course and you spend 15 minutes skimming
lesson 5 then it is reasonable to plan on spending 25% of your total time
on lesson 5. If you allow thirty hours for the course then you can expect
to spend about seven hours on lesson 5.
Set a starting date and a finishing date as targets. If you allow yourself
thirty hours to do the whole course and if you commit three hours per week
then the course will take ten weeks. Pick a date to start and stick to
it! Only death and sickness should prevent your starting! Possibly a large
win on the lottery might also delay the start.
Set a time each week for the lessons, the same time each week. Remember
this is a discipline of time management. If you have set aside three hours
per week and you have estimated how long you have to spend on each lesson
then you have a very good idea of where you will be through the course
at any given time. Now write down a timetable. Keep a diary on your progress
and check it against your timetable.
Few people can remember complex things at the first go. Be prepared
to go back over things. Most days I can barely remember what I had for
breakfast but I do know where to go to check things. My own learning habits
depend very much on reinforcement, that is, re-visiting lessons and doing
practice exercises. A particularly good way to learn practical skills is
to invent your own exercises.
And last of all: There are three golden rules for the exercises and
questions:
- Do the exercises and questions
- Do the exercises and questions
- Do the exercises and questions
If you can't remember the three rules, just do the exercises and questions.
Return to the top of this page
This publication is copyright David Beech and Learning Systems 1997-2002 and may not be reproduced by any means without the written permission of
David Beech
9 Wyndella Street, Tasmania, Australia
db@codelearn.com