Overview of Programming Languages
Computer Program
• A program is a set of instructions following the rules of the chosen language.
• Without programs, computers are useless.
• A program is like a recipe.
• It contains a list of ingredients (called variables) and a list of directions (called statements) that tell the computer what to do with the variables.
Programming Language
• A vocabulary and set of grammatical rules (syntax) for instructing a computer to perform specific tasks.
• Programming languages can be used to create computer programs.
• The term programming language usually refers to high-level languages, such as BASIC, C, C++, COBOL, FORTRAN, Ada, and Pascal.
Programming Language
• You eventually need to convert your program into machine language so that the computer can understand it.
• There are two ways to do this:
o Compile the program
o Interpret the program
Programming Language
Compile is to transform a program written in a high-level programming language from source code into object code.
• This can be done by using a tool called compiler.
• A compiler reads the whole source code and translates it into a complete machine code program to perform the required tasks which is out put as a new file.
Interpreter is a program that executes instructions written in a high-level language.
• An interpreter reads the source code one instruction or line at a time, converts this line into machine code and executes it.
Programming Language
A compiled language is a programming language which are generally compiled and not interpreted. It is one where the program, once compiled, is expressed in the instructions of the target machine; this machine code is undecipherable by humans. Types of compiled language – C, C++, C#, CLEO, COBOL, etc.