Department of Engineering

IT Services

1. Introduction

What is a computer program?

department imageComputers process data, perform computations, make decisions and instigate actions under the control of sets of instructions called computer programs. The computer (central processing unit, keyboard, screen, memory, disc) is commonly referred to as the hardware while the programs that run on the computer (including operating systems, word processors and spreadsheets) are referred to as software.

Program instructions are stored and processed by the computer as a sequence of binary digits (i.e. 1's and 0's) called machine code. In the early days programmers wrote their instructions in strings of numbers called machine language. Although these machine instructions could be directly read and executed by the computer, they were too cumbersome for humans to read and write. Later assemblers were developed to map machine instructions to English-like abbreviations called mnemonics (or assembly language). In time, high-level programming languages (e.g. FORTRAN (1954), COBOL (1959), BASIC (1963) and PASCAL (1971)) developed which enable people to work with something closer to the words and sentences of everyday language. The instructions written in the high-level language are automatically translated by a compiler (which is just another program) into binary machine instructions which can be executed by the computer at a later stage.

Note that the word "program" is used to describe both the set of written instructions created by the programmer and also to describe the entire piece of executable software.

The C++ Programming Language

The C++ programming language (Stroustrup (1988)) evolved from C (Ritchie (1972)) and is emerging as the standard in software development. For example, the Unix and Windows operating systems and applications are written in C and C++. It facilitates a structured and disciplined approach to computer programming called object-oriented programming. It is a very powerful language and in its full form it is also a rich language. However, in this course, only the basic elements of C++ will be covered.

Back to top