We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 27
Credit Hours
BBS 3 hours Unit 2: Programming Language and Language Translator Lecture Hours: 3hrs.
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours
Programming Language : Introduction
Types of Programming Language : oMachine Level Language oAssembly Level Language oHigh level Language Language Translator: Introduction Types of Language Translator : o Assembler o Compiler o Interpreter Compiled by: Er. Jeet Narayan Yadav Credit Hours BBS 3 hours
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours A programming language is a computer language that is used by programmers (developers) to communicate with computers. A programming language is an artificial language that can be used to control the behaviour of a machine, particularly a computer. Programming languages, like human languages, are defined through the use of syntactic and semantic rules i.e. a set of symbols, grammars and rules to determine structure and meaning respectively It is a set of instructions written in any specific language ( C, C++, Java, Python) to perform a specific task. The programmer communicates with a machine using programming languages. Most of the programs have a highly structured set of rules.
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours Most Popular Programming Languages – Fortran Pascal QBASIC PASCAL C C++ Python Java C# PHP JavaScript Perl etc. Compiled by: Er. Jeet Narayan Yadav Credit Hours BBS 3 hours Characteristics of a programming Language – A programming language must be simple, easy to learn and use, have good readability, and be human recognizable. A portable programming language is always preferred. Programming language’s efficiency must be high so that it can be easily converted into a machine code and executed consumes little space in memory. A programming language should be well structured and documented so that it is suitable for application development. The language must be platform independent i.e the program developed using the programming language can run on any computer system.
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours
Characteristics of a programming Language –
The programs developed in the language must make efficient use of memory as well as other computer resources Necessary tools for the development, debugging, testing, maintenance of a program must be provided by a programming language. A programming language should provide a single environment known as Integrated Development Environment(IDE). A programming language must be consistent in terms of syntax and semantics.
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours The primary classifications of programming languages are:
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours Machine Level Language Low-Level language is the only language which can be understood by the computer. Low-level language is also known as Machine Language. The machine language contains only two symbols 1 & 0. All the instructions of machine language are written in the form of binary numbers 1's & 0's. A computer can directly understand the machine language. It is very difficult to understand, but it is the only thing that the computer can work with. All programs and programming languages eventually generate or run programs in machine language. Machine language is made up of instructions and data that are all binary numbers.
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours
Machine Level Language
The ASCII character 'A' is the same as 65 Machine language example Below is an example of machine language (binary) for the text "Hello World."
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours Assembly Language (middle level language) Middle-level language is a computer language in which the instructions are created using symbols such as letters, digits and special characters. Assembly language is an example of middle-level language. In assembly language, we use predefined words called mnemonics. Binary code instructions in low-level language are replaced with mnemonics and operands in middle- level language. But the computer cannot understand mnemonics, so we use a translator called Assembler to translate mnemonics into machine language. Assembler is a translator which takes assembly code as input and produces machine code as output. That means, the computer cannot understand middle- level language, so it needs to be translated into a low-level language to make it understandable by the computer. Assembler is used to translate middle-level language into low-level language. Compiled by: Er. Jeet Narayan Yadav Credit Hours BBS 3 hours
Compiled by: Er. Jeet Narayan Yadav
Credit Hours BBS 3 hours High Level Language(HLL) High-level language is a computer language which can be understood by the users. The high-level language is very similar to human languages and has a set of grammar rules that are used to make instructions more easily. Every high-level language has a set of predefined words known as Keywords and a set of rules known as Syntax to create instructions. The high-level language is easier to understand for the users but the computer can not understand it. High-level language needs to be converted into the low-level language to make it understandable by the computer. We use Compiler or interpreter to convert HLL to Low Level Language(LLL). Compiled by: Er. Jeet Narayan Yadav Credit Hours BBS 3 hours High Level Language(HLL) Languages like FORTRAN,C, C++, JAVA, Python, etc., are examples of high-level languages. All these programming languages use human-understandable language like English to write program instructions. These instructions are converted to low-level language by the compiler or interpreter so that it can be understood by the computer.