0% found this document useful (0 votes)
72 views

Fundamentals: Chapter - 04 & 05 Powered By: Computer Fundamental Team

The document discusses different types of programming languages including machine-level languages, assembly languages, high-level languages, and scripting languages. It provides details on each type of language such as their characteristics, how they are executed, advantages and limitations. Machine-level languages consist of binary instructions directly understood by computers while assembly languages use mnemonics to represent machine code. High-level languages are easier for humans to read and write but require compiling or interpreting. Scripting languages allow automating tasks through an interpreter in an application or operating system environment.

Uploaded by

kk
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
72 views

Fundamentals: Chapter - 04 & 05 Powered By: Computer Fundamental Team

The document discusses different types of programming languages including machine-level languages, assembly languages, high-level languages, and scripting languages. It provides details on each type of language such as their characteristics, how they are executed, advantages and limitations. Machine-level languages consist of binary instructions directly understood by computers while assembly languages use mnemonics to represent machine code. High-level languages are easier for humans to read and write but require compiling or interpreting. Scripting languages allow automating tasks through an interpreter in an application or operating system environment.

Uploaded by

kk
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 31

Vishwakarma Institute of Information

Technology
Computer Fundamentals (NCB)
Unit-I Introduction to Computer
Fundamentals
Types of Programming Languages and
Introduction to Compiler, Interpreter,
Assembler, Linker
Academic Year: 2018-19 Chapter – 04 & 05
Powered by: Computer Fundamental Team
Types of Programming Languages
Introduction
In this chapter you will learn about :
• Introduction to computer program
• Types of Programming Languages
• Machine-level, assembly-level, High-level
Language and Scripting Language
• Introduction to Compiler, Interpreter, Assembler,
Linker

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages

What is Computer Program?

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
What is Computer Program?
• A computer program is a sequence of instruction for performing a task
designed to solve specific problems. Each program instruction is designed to
be executable by a computer; computers require the capacity to execute
programs in order to function.
• The instructions of a computer program are often specified by a computer
programmer. A computer programmer does this by means of the application
of a programming language.
• The program in its human-readable form of source code, a compiler can
derive machine code, which are computer program instructions that—as a
result of being specified in a language that a computer can understand—are
able to be directly executed by the computer they have been provided to.
Alternatively, a computer program may be executed with the aid of an
interpreter.

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
Programming languages
• Computer programs can be categorized by the programming
language paradigm used to produce them. Two of the main
paradigms are imperative and declarative.
• Imperative programming languages specify a sequential
algorithm using declarations, expressions, and statements.
• Declarative programming languages describe what
computation should be performed and not how to compute it.
• Declarative programs omit the control flow and are considered
sets of instructions. Two broad categories of declarative
languages are functional languages and logical languages.

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
Broad Classification of Computer Language

Machine-level,

Assembly-level,

High-level
Language and
Scripting
Language
Unit-I Introduction to Computer Fundamentals
Types of Programming Languages
Machine-level Language

• Only language of a computer understood by it


without using a translation program
• Normally written as strings of a binary 1s and 0s
• Machine language is the lowest-level programming
language. Machine languages are the only
languages understood by computers. Machine
languages are almost impossible for humans to use
because they consist entirely of numbers.

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
Machine-level Language

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
Machine-level Language

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
Machine-level Language

Advantage:
• Can be executed very fast
Limitations:
• Machine dependent
• Difficult to program
• Error prone
• Difficult to modify

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
Assembly/ Symbolic Language

• An assembly (or assembler) language, often abbreviated asm, is any


low-level programming language, in which there is a very strong (but
often not one-to-one) correspondence between the assembly program
statements and the architecture's machine code instructions.
• Each assembly language is specific to a particular computer architecture.
• Assembly language may also be called symbolic machine code.
• Assembly code is converted into executable machine code by a utility
• program referred to as an assembler. The conversion process is
• referred to as assembly, or assembling the source code. Assembly time
is the computational step where an assembler is run.

Unit-I Introduction to Computer Fundamentals


Introduction to Assembler
Assembler

Unit-I Introduction to Computer Fundamentals


Introduction to Assembler
Assembler
• An assembler program creates object code by translating combinations
of mnemonics and syntax for operations and addressing modes into
their numerical equivalents. This representation typically includes an
operation code ("opcode") as well as other control bits and data.
• The assembler also calculates constant expressions and resolves
symbolic names for memory locations and other entities.
• The use of symbolic references is a key feature of assemblers, saving
tedious calculations and manual address updates after program
modifications.
• Most assemblers also include macro facilities for performing textual
substitution – e.g., to generate common short sequences of instructions
as inline, instead of called subroutines.

Unit-I Introduction to Computer Fundamentals


Introduction to Assembler
Assembler

Unit-I Introduction to Computer Fundamentals


Introduction to Assembler
Assembler

Advantages of Assembly language over Machine Language:


• Easier to understand and use
• Easier to locate and collect error
• Easier to modify
• No worry about the addresses
• Easy Relocatable
• Efficiency of machine language

Unit-I Introduction to Computer Fundamentals


Introduction to Assembler
Assembler

Limitation of Assembly language:


• Machine Dependent
• Knowledge of Hardware is required
• Machine level coding

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
High Level Language

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
High Level Language

Advantages of High-Level Language:


• Machine Independent
• Easier to learn and use
• Fewer errors during program development
• Lower program preparation cost
• Better documentation
• Easier to maintain

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
High-Level Language

Limitation of High-Level language:


• Lower execution efficiency
• Less flexibility to control the computer’s CPU. Memory
and registers

Unit-I Introduction to Computer Fundamentals


Introduction to Compiler
Compiler

Unit-I Introduction to Computer Fundamentals


Introduction to Compiler
Compiler

Unit-I Introduction to Computer Fundamentals


Introduction to Compiler
Compiler

Unit-I Introduction to Computer Fundamentals


Introduction to Compiler
Compiler

Unit-I Introduction to Computer Fundamentals


Introduction to Linker
Linker

Unit-I Introduction to Computer Fundamentals


Introduction to Linker
Linker

Unit-I Introduction to Computer Fundamentals


Introduction to Interpreter
Interpreter

Unit-I Introduction to Computer Fundamentals


Introduction to Interpreter
Role of Interpreter

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
Benefits of Intermediate language Compiler and Interpreter

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
Intermediate language Compiler and Interpreter

Unit-I Introduction to Computer Fundamentals


Introduction to Computer Program
Scripting Language

• A scripting or script language is a programming language that supports scripts:


programs written for a special run-time environment that automate the execution of
tasks that could alternatively be executed one-by-one by a human operator. Scripting
languages are often interpreted (rather than compiled). Primitives are usually the
elementary tasks or API calls, and the language allows them to be combined into more
complex programs. Environments that can be automated through scripting include
software applications, web pages within a web browser, usage of the shells of operating
systems (OS), embedded systems, as well as numerous games.
• A scripting language can be viewed as a domain-specific language for a particular
environment; in the case of scripting an application, it is also known as an extension
language. Scripting languages are also sometimes referred to as very high-level
programming languages, as they operate at a high level of abstraction, or as control
languages, particularly for job control languages on mainframes.

Unit-I Introduction to Computer Fundamentals


Types of Programming Languages
Scripting Language

• The term "scripting language" is also used loosely to refer to dynamic high-level
general-purpose languages, such as Perl, PowerShell, Python, and Tcl with the
term "script" often used for small programs (up to a few thousand lines of
code) in such languages, or in domain-specific languages such as the text-
processing languages sed and AWK.
• The spectrum of scripting languages ranges from very small and highly domain-
specific languages to general-purpose programming languages used for
scripting. Standard examples of scripting languages for specific environments
include: Bash, for the Unix or Unix-like operating systems; ECMAScript
(JavaScript), for web browsers; and Visual Basic for Applications, for Microsoft
Office applications.

Unit-I Introduction to Computer Fundamentals

You might also like