Please enable JavaScript.
Coggle requires JavaScript to display documents.
Introduction To Programming - Coggle Diagram
Introduction To Programming
1.1 Programming Languages
Low-level Languages
Machine Language
Advantages :
Instructions created using machine language are readily understood by the computer because it does not need to be translated before being executed.
Disadvantages :
i. Difficult to learn
ii. Programs are lengthy because a single instruction of machine language corresponds to only one operation at the machine level
iii. Machine-dependent; can only be used on the machine it is originally created for.
Assembly Language
Advantages :
Easier to learn and understand
Disadvantages :
i. Not readily understood by computers
ii. Needs to be translated into machine language before being executed
iii. Programs are lengthy because a single instruction of machine language corresponds to only one operation at the machine level
iv. Machine-dependent; can only be used on the machine it is originally created for
High-level Language
Disadvantages :
Not readily understood by computers
Advantages :
i. Easier to learn and understand
ii. Programs are shorter because a single instruction of high level language corresponds to many operation at the machine level
iii. Machine-dependent; can run on different types of computers and operating systems
1.2 Programming Paradigms
Procedural
Advantages :
i. More readable and easier to maintain
ii. Can reuse the code
C
Pascal
ColdFusion
Based on the concept of modular programming
Programmer identifies the major function of a program called the main module and the main module is divided into smaller modules.
Object-oriented
Advantages :
i. Code reusability
ii. Avoid programming redundancy
iii. Programmers create applications faster
Java
C++
Python
Based on objects and classes
Programmer identifies objects which are items that can contain both data and the procedures that read or manipulate that data.
Logic
Advantages :
i. System solve the problem , the programming steps themselves are kept to a min
ii. Proving the validity of a given program is simple
LISP
Prolog
Set of sentences in logical form, expressing facts and rules about some problem domain.
Focus on facts stored in memory called the knowledge base.
1.3 Programming Language Translators
Assembler
Programs written in assembly language
—> machine language
Interpreter
High-level programming language
—> machine language one line at a time
Compiler
The entire source code of high-level programming language
—> machine language