Chapter 4- Programming Languages and Software Development Tools
Chapter 4- Programming Languages and Software Development Tools
Objectives
4.1. Introduction
The languages are classified as low because they can be easily understood by the computer
directly or they require less effort to translate them into computer understandable form.
In this language, instructions are written using binary logic. Given that data and instructions
are in binary form, many lines of codes are needed to accomplish a simple task. For example for
adding two numbers the program written in machine language look like this.
11100110 00000011
00001111 10001101
10001111 11111111
The program is hard for human to understand but it’s easily understood by computers. A
machine code is directly executed by the computer’s processor.
This language was developed to overcome the difficulties of understanding and using machine
language. It helps the programmers to write programs as a set of Symbolic operation Codes
called Mnemonics.
Mnemonics are basically shortened two or three letter words. A sample program written in
assembly language is shown below.
MOV AX, 15 - (means move 15 to register AX)
SUB AX, 10 -( Subtract 10 from the value in AX)
Programs written in assembly language required an assembler to convert them into machine code
for the computer to execute them.
B. Disadvantages
They are machine dependent , they are not portable that means a program written for
one computer can not be installed and used on another computer of different family.
They are difficult and cumbersome to use and learn
Require highly trained experts to both develop and maintain programs
Debugging program is difficult
These languages are very close to the human language (English – like) and they can be read and
understood even by people who are not experts in programming.
The following statement written in High Level Language adds two numbers. It shows how easy
it is to understand.
Sum := FirstNumber + SecondNumber.
A source code is a program written in High Level Language or Assembly Language that a
programmer enters through a source code editor.
There are many different high-level programming languages in use today including
C++, Delphi, Java, Pascal, Python, Visual Basic and many more. Once a programmer
has learnt the techniques of programming in any high-level language, these can be
transferred to working in other high-level languages.
These languages are used to create web pages. The standard Markup language used to create
web pages is called HTML( Hyper Text Markup language). The HTML consists of tags.
Examples of HTML tags and meaning.
Some special block of codes called scripts may be inserted into HTML pages using scripting
languages. Some examples of web scripting languages are: HTML, JavaScript, and CSS.
programs written in a high-level language are easier to read and understand as the
language used is closer to human language
Programs are written in a shorter time
It easy to maintain once in use.
Programs are portable (not machine dependent).
B. disadvantages
programs are executed more slowly
Require larger CPU storage capacity for compilation.
They have to be translated into machine readable form before.
4.4. Translators
Computer programs can exist in several forms. Programs are written by humans in a form that
people who are trained as computer programmers can understand. In order to be used by a
computer, programs need to be translated into the binary instructions, or machine code, that the
computer understands this is done by a utility program called a translator.
Examples of translators are:
Compilers
Interpreters
Assemblers
4.4.1. Compilers
.
MR. HOYOKSOU GOLSIA BLAISE RAOUL Page | 4
TOPIC: ALGORITHMS [PROGRAMMING LANGUAGES & SOFTWARE DEVELOPMENT ]
4.4.2. Interpreters
4.4.3. Assemblers
These are software used for developing application (programs) there are different kind of
software tools for instance translators, editors, debuggers , linkers and IDEs.
A. Text editor
An editor is a piece of computer software for creating and editing plain text. It does not support
document formatting as the word processor does. A text editor can be used to write email,
compose web page, write computer program. For example Notepad, Wordpad.
A source code editor is a text editor designed specially for editing source code of computer
programs. I could be a stand alone application or may be built into An Integrated Development
Environment(IDE).
C. Linkers
A linker is a software that is used to combine object code modules ( sub programs) together to
make a complete program.
D. Debugger
A software bug is an error ,mistake ,failure or fault in a computer program that produces an
unexpected result.
A debugger is a software that is used to remove bugs from a program. The process of removing
bugs or mistake from a program is called debugging.
Imperative paradigm: programs are written using sequence of instructions that are
executed by the processor; it manipulates variables and data structures. C, PASCAL,
FORTRAN are example of imperative paradigm programming languages.
Functional paradigm: Here, programs development is the construction of mathematical
functions. A solution to a problem consist of series of functions calls. E.g Lisp,ML.
Logic paradigm: logic programming consist of set of facts and rules. A knowledge base
is built up trough facts and rules about a specific area of expertise. E.g PROLOG.
Object Oriented Programming (OOP): The concept behind OOP languages is to look
at a program as having various objects interacting together to achieve a common goal.
Each object has a specific data values that are unique to it ( called State) and a set of the
this it can accomplish called ( functions or behavior). This process of having data and
functions that operate on the data within an object is called Encapsulation. Examples of
OOP languages are Java , Simula, Python