You are on page 1of 7

ASSIGNMENT

ON

1. DIFFERENCES BETWEEN PROCEDURAL AND NON-


PROCEDURAL LANGUAGES
2. ATLEAST 5 EXAMPLES OF EACH OF THE PROCEDURAL
AND NON-PROCEDURAL LANGUAGES
3. FOUR EXAMPLES OF THE DIFFERENT GENERATION OF
PROGRAMMING LANGUAGES
4. DISCUSSION ON THE MENTIONED APPLICATION DOMAIN

WRITTEN BY:
SALMAN-YUSUF KHALID OLANIYI
21/03SEN056

COURSE CODE: SEN415

COURSE TITLE:
CONCEPT OF PROGRAMMING LANGUAGE
ANSWER

1. DIFFERENCES BETWEEN PROCEDURAL AND NON-PROCEDURAL


LANGUAGES.
In the realm of computer programming and software development, there are
two fundamental categories of programming languages that exist. The procedural and
non-procedural languages. These languages both have distinct and specific purposes
and other different approaches to problem-solving and the way their codes are
organized.
Procedural Languages: These are languages that are centered around
procedures or routines. These routines or procedures are sequence of instructions that
are executed sequentially. User has to specify “What to do” and also “How to do”.
These instructions are written to solve specific problems
Non-Procedural Languages: These are declarative languages, they differ
from procedural languages. They are also know as applicative or functional languages.
User has to only specify “What to do” and not “How to do”. These languages focus
on defining relationships, constraints and rules

Key Differences
1. Focus
a) Procedural: Focuses on specifying “What” and “How” to do something.
b) Non-Procedural: Focuses on specifying only “What” needs to be done.
2. Abstraction level
a) Procedural languages operate on at a lower level of abstraction.
b) Non-procedural languages works on a more higher level of abstraction.
3. Programmer Control
a) Procedural languages gives programmer detailed control of implementaion
and system resources. Hence more flexibility.
b) Non-procedural languages limits programmer control over low-level detail.
Less flexible but can be easier to code.
2. ATLEAST 5 EXAMPLES OF EACH OF THE PROCEDURAL AND NON-
PROCEDURAL LANGUAGES
Procedural Languages
 C - Imperative structured language ideal for system/hardware access.
 Pascal - Heavily structured for teaching procedural programming.
 Fortran - One of the oldest procedural languages, popular in
science/engineering.
 BASIC - Designed as easy beginner language with a procedural approach.
 C# - Robust OOP language on .NET framework, similar to java.
 JAVA - OOP language supporting portability across platforms
Non-procedural languages
 SQL - Declarative language for relational database across and mangement
 PROLOG - A logic programming language where programs are structured
around facts and rules rather than step by step instructions.
 TensorFlow - Neural network library uses a declarative style to constuct
models
 XSLT - XML document transformation declaratively defines rules
 Jquery - Javascript library with non-procedural style event handling
 Functional Programming languages (Haskell, LISP)
3. MENTION FOUR EXAMPLES OF THE DIFFERENT GENERATION OF
PROGRAMMING LANGUAGES
A. First Generation Language (1GL): Machine Language - The first generation of
programming languages, also known as machine language (1GL), programming
wasn't conducted using traditional programming languages as we understand them
today. So there were no distinct programming languages per se in the first generation.

B. Second Generation Language (2GL): Assembly Language - In the second


generation of programming languages (2GL), assembly language was predominant. It
offered a significant improvement over machine language (1GL) by using mnemonics
to represent machine instructions, making programming more human-readable than
raw binary code.
Examples:
1. Assembly Language for IBM 704
2. Mnemonics for IBM 650
3. Symbolic Optimal Assembly Program (SOAP)
4. Autocode for Ferranti Mark I

C. Third Generation Language (3GL): High-Level Language - In the third generation


of programming languages (3GL), several high-level languages emerged, allowing
programmers to write instructions using more human-readable syntax and abstracted
away from machine-level details.
Examples:
1. Fortran
2. COBOL (Common Business-Oriented Language)
3. C Programming Language
4. BASIC (Beginner’s All-purpose Symbolic Instruction Code)

D. Fourth Generation Language (4GL): High-Level Declarative Language - In the


fourth generation they deal with the following field, which become more and more
important. The Database and Query Languages and The program or application
Generators.
Examples:
1. SQL (Structured Query Language)
2. MATLAB (Matrix Laboratory)
3. Perl (Practical Extraction and Reporting Language)
4. R (Statistical Computing and Graphics)

E. Fifth GenerationLanguage (5GL): Constraint-Based and Logic Programming - In


the fifth generation of programming languages (5GL), the focus shifted towards
constraint-based and logic programming paradigms. These languages aimed to
provide an even higher level of abstraction and facilitate the development of complex
systems by utilizing constraints and logic for problem-solving.
Examples:
1. Prolog (Programming in Logic)
2. OPS5
3. Mercury
4. KL-ONE
4. DISCUSSION ON THE MENTIONED APPLICATION DOMAIN
Application Domains
1. Scientific Application
2. Data Processing Application
3. Text Processing Application
4. AI Application
5. System Programming Application

Scientific Application Domain


In scientific study and analysis, programming languages are essential. Large libraries
and tools tailored for scientific computations, data analysis, and visualization are
available in languages like R, MATLAB, and Python. These languages enable
researchers in disciplines like physics, biology, chemistry, and engineering to carry
out intricate mathematical computations, statistical analyses, and simulations. Their
talents support data representation, modeling, and experimentation, leading to ground-
breaking findings.
Data Processing Application Domain
Languages such as Python, Java, and Scala are prominent in data processing. With the
rise of Big Data, these languages leverage robust frameworks like Pandas, Hadoop,
and Spark to handle large-scale data manipulation, transformation, and analytics.
They facilitate tasks like data cleaning, aggregation, machine learning model training,
and predictive analytics, contributing to informed decision-making across various
industries.
Text Processing Application Domain
The world of text and language comes alive through the magic of programming
languages. Natural language processing (NLP) frameworks like NLTK and spaCy,
built upon Python, allow developers to tackle tasks like machine translation,
information retrieval, and sentiment analysis. These applications reshape the way we
interact with information, paving the way for personalized search engines, intelligent
chatbots, and insightful marketing campaigns.
AI Application Domain
The rise of artificial intelligence has ushered in a new era of automation and
intelligent decision-making. Programming languages like TensorFlow and PyTorch
provide the foundation for developing and training AI models. These models, fueled
by machine learning and deep learning algorithms, play a crucial role in computer
vision, robotics, and expert systems, transforming industries and enhancing our
everyday lives.
System Programming Application Domain
Languages like C, C++, and Rust are essential in system programming. They provide
direct access to system resources, making them suitable for tasks involving hardware
interaction, memory management, and operating system functions. These languages
are used in developing operating systems, device drivers, embedded systems, and
network protocols due to their efficiency and control over system resources

You might also like