Programming

Main Topics of Study:

A. Overview

  • The difference between different types of languages from assembler, through high level languages to 4GLs and object-oriented languages. An outline history of the development of languages over the years
  • Differences between procedural and declarative languages
  • Summary of the stages of the translation process – compiler and interpreter
  • An appreciation of assembly language code through a limited set of operation codes. How these build into a program. Writing full programs is not required

B. Program Development

  • Overview of the stages of program development from receiving a program specification to handing over a fully tested and documented program applied to a professional programmer. Candidates should have an appreciation of the difference of scale of real programs compared with classroom exercises
  • Initial understanding of the problem. Checking details with the systems analyst
  • Create algorithms for real problems
  • Comparison of different algorithmic methods – flowcharts, pseudo-code, decision tables, Jackson charts. Advantages and disadvantages of each
  • Define structured programming and construct. The three main constructs – sequence, selection, iteration. Top down programming
  • Modular programming. How modular program can be implemented. Advantages and disadvantages of their use
  • Prototyping. Advantages and disadvantages of its use

C. Input and Output of data

  • Data types and the operations that can be performed with each
  • Keyboard entry of data. Handling and correcting invalid data
  • Standard output layouts. Invoices. Account ledgers
  • Design a layout for a given situation. This must be workable in the real world
  • Differences between output on a screen and a printer

D. Filing data

  • The need for files. The consequences of filing systems not being available
  • File structure. Organisation and access methods. An appreciation that a file might be accessed for more than one purpose and so determining the method of organisation
  • Programming for serial and sequential files. Commands relating to file handling – open, close, read, write, check end of file, append
  • Programming to locate records from the whole file that satisfy a given condition
  • Programming to accumulate values from each record in a file
  • Programming to merge two similar files into one
  • Sequential master file update from an unsorted transaction file. Candidates will not be expected to program for this

E. Handling data in memory

  • Variables – rules for naming variables/procedures/functions
  • Performing calculations
  • Decisions – IF, CASE
  • Loops. Difference between the three main looping features and when to use them
    • FOR/ENDFOR for fixed number of repeats
    • REPEAT/UNTIL for variable repeats – the process is always executed at least once – test for exit at the end
    • WHILE/ENDWHILE for variable repeats – the process may not execute even the first time in rare situations – test for exit at the beginning. Use of data TERMINATORS
  • Arrays – 1-dimensional and 2-dimensional
    • Read all data into an array
    • Output all data from an array
    • Search an array for a given value
    • Accumulate values held in some elements of an array
    • Use one array to find data to access another
  • Text data – extract character(s) from a string. Joining strings

F. Procedures/Sub routines and Functions

  • Use of procedures for structuring and re-use processes. Library of procedures/functions
  • Parameter passing. Calling a procedure. How parameters are handled internally
  • Difference between procedures and functions
  • Standard functions such as:
    • Numeric – SQRT, ABS, INT, RANDOM, SIN/COS/TAN
    • String – LEFT, RIGHT, ASC, VALUE. {The names may vary in different languages}

G. Testing

  • Plan the structure of test data for a program
  • Design test data for valid and invalid situations
  • Perform a dry run/desk check using test data and an algorithm – lay out the results in table format showing the value of variables only as they change
  • Programming to test invalid conditions and subsequent repeated re-entry after data is rejected until it is finally accepted
  • Testing by program. Recording the results in a test log. Levels of testing – module, program, system, user acceptance
  • Methods of locating errors of logic – dry run, trace routines, test bed routines, temporary print commands inserted
  • Difference between syntax and logic errors. How and when syntax and logic errors are detected and corrected

H. Documentation

  • The need for documentation
  • Documentation for the maintenance programmer
  • Documentation for the user
  • The reasons why user and maintenance programmer documentations are different
  • Uses and benefits of comments/annotations in program listings

F