SlideShare a Scribd company logo
1 of 3
Lectures of Data Structures and Algorithm
08-Oct-13
Definition of Data Structure and Algorithm:The arrangement/manipulation of data by the
compiler in computer memory.
Types of Data Structure:1. Physical Data Structure
2. Logical Data Structure
Examples of Data Structure:1.
2.
3.
4.
5.
6.

Stat
Queue => De-Queues
Array
Graph
Sorting
Tree

*Physical DS:-.
Physical memory of data by the
translator.
*Logical DS:Logical concept of data by the
translator.

09-Oct-13
Types of Data Structure:1) Physical Data Structure:a) Linear Physical Data Structure(e.g. Array , Queue , Stat)
b) Non-Linear Physical Data Structure(e.g. Link list, Tree, Graph)

2) Logical Data Structure:a) Linear Logical Data Structure
b) Non-Linear Logical Data Structure

Levels of Data Structure:Abstract Level
Application Level
Implementation Level
1) Abstract Level:In abstract way….. (sarsari tor per)
Extra:2) Application Level:Array:Source code adding on a thing.
 Homogeneous
 Sequential order
 Not Flexible (Fix)

3) Implementation Level:Executable code adding on a thing.

Link-List:-

Bubble Sort:-

 NonHomogeneous
 Non-Sequential
 Flexible

Step 1
2
2
2
2
2
2
2
2
Step 2

9
9
4
4
4
4
4
4

2
2
2
2
2
2
Step 3

4
4
9
1
1
1
1
1

4
1
1
1
1
1

2
1
1
2
1
2
1
2
1
2
1
2
1
2
Logical method:while(a[i]>a[i+1]){
//Swaping;a=b

1
1
1
9
5
5
5
5

5
5
5
5
9
6
6
6

6
6
6
6
6
9
7
7

7
7
7
7
7
7
9
8

8
8
8
8
8
8
8
9

1
4
4
4
4
4

5
5
5
5
5
5

6
6
6
6
6
6

7
7
7
7
7
7

8
8
8
8
8
8

9
9
9
9
9
9

4
4
4
4
4
4
4

5
5
5
5
5
5
5

6
6
6
6
6
6
6

7
7
7
7
7
7
7

8
8
8
8
8
8
8

9
9
9
9
9
9
9
b=c
c=a
}
Definition of Algorithm:Set of instructions is called Algorithm.
OR
Non-executable code is called Algorithm.

It don’t have “;” or other
statement ending words.

More Related Content

What's hot (17)

Data structures
Data structuresData structures
Data structures
 
Presentation on Data Structure
Presentation on Data StructurePresentation on Data Structure
Presentation on Data Structure
 
introduction to Data Structure and classification
 introduction to Data Structure and classification introduction to Data Structure and classification
introduction to Data Structure and classification
 
20130626 OpenRefine Introduction
20130626 OpenRefine Introduction20130626 OpenRefine Introduction
20130626 OpenRefine Introduction
 
Types of datastructures
Types of datastructuresTypes of datastructures
Types of datastructures
 
Lecture1 data structure(introduction)
Lecture1 data structure(introduction)Lecture1 data structure(introduction)
Lecture1 data structure(introduction)
 
Linked list
Linked listLinked list
Linked list
 
Singly Linked List
Singly Linked ListSingly Linked List
Singly Linked List
 
Elementary data organisation
Elementary data organisationElementary data organisation
Elementary data organisation
 
Data structure
Data structureData structure
Data structure
 
Lecture 1
Lecture 1Lecture 1
Lecture 1
 
General Data structures
General Data structuresGeneral Data structures
General Data structures
 
Lecture 1 data structures and algorithms
Lecture 1 data structures and algorithmsLecture 1 data structures and algorithms
Lecture 1 data structures and algorithms
 
Abstract data types (adt) intro to data structure part 2
Abstract data types (adt)   intro to data structure part 2Abstract data types (adt)   intro to data structure part 2
Abstract data types (adt) intro to data structure part 2
 
data structure
data structuredata structure
data structure
 
Data structure and its types.
Data structure and its types.Data structure and its types.
Data structure and its types.
 
Introduction to stack
Introduction to stack Introduction to stack
Introduction to stack
 

Viewers also liked

Data structure and its types
Data structure and its typesData structure and its types
Data structure and its typesNavtar Sidhu Brar
 
Data Structures and Algorithms
Data Structures and AlgorithmsData Structures and Algorithms
Data Structures and AlgorithmsPierre Vigneras
 
Data structures (introduction)
 Data structures (introduction) Data structures (introduction)
Data structures (introduction)Arvind Devaraj
 
Data structure and its types
Data structure and its typesData structure and its types
Data structure and its typesNavtar Sidhu Brar
 
DATA STRUCTURES
DATA STRUCTURESDATA STRUCTURES
DATA STRUCTURESbca2010
 

Viewers also liked (6)

Data structure and its types
Data structure and its typesData structure and its types
Data structure and its types
 
Data Structures and Algorithms
Data Structures and AlgorithmsData Structures and Algorithms
Data Structures and Algorithms
 
Data structures (introduction)
 Data structures (introduction) Data structures (introduction)
Data structures (introduction)
 
Data structure and its types
Data structure and its typesData structure and its types
Data structure and its types
 
Data Structure
Data StructureData Structure
Data Structure
 
DATA STRUCTURES
DATA STRUCTURESDATA STRUCTURES
DATA STRUCTURES
 

Similar to Data structures and algorithm

1. Data structures introduction
1. Data structures introduction1. Data structures introduction
1. Data structures introductionMandeep Singh
 
Data Structure # vpmp polytechnic
Data Structure # vpmp polytechnicData Structure # vpmp polytechnic
Data Structure # vpmp polytechniclavparmar007
 
Iare ds lecture_notes_2
Iare ds lecture_notes_2Iare ds lecture_notes_2
Iare ds lecture_notes_2RajSingh734307
 
Chapter 1( intro & overview)
Chapter 1( intro & overview)Chapter 1( intro & overview)
Chapter 1( intro & overview)MUHAMMAD AAMIR
 
Introduction to Data Structure.pptx
Introduction to Data Structure.pptxIntroduction to Data Structure.pptx
Introduction to Data Structure.pptxGlenardDSarmiento
 
Preparing for BIT – IT2301 Database Management Systems 2001e
Preparing for BIT – IT2301 Database Management Systems 2001ePreparing for BIT – IT2301 Database Management Systems 2001e
Preparing for BIT – IT2301 Database Management Systems 2001eGihan Wikramanayake
 
Introduction to data structure ppt
Introduction to data structure pptIntroduction to data structure ppt
Introduction to data structure pptNalinNishant3
 
Introduction to DS.pptx
Introduction to DS.pptxIntroduction to DS.pptx
Introduction to DS.pptxOnkarModhave
 
DS-UNIT 1 FINAL (2).pptx
DS-UNIT 1 FINAL (2).pptxDS-UNIT 1 FINAL (2).pptx
DS-UNIT 1 FINAL (2).pptxprakashvs7
 
Data Structures_Introduction
Data Structures_IntroductionData Structures_Introduction
Data Structures_IntroductionThenmozhiK5
 
introduction about data structure_i.pptx
introduction about data structure_i.pptxintroduction about data structure_i.pptx
introduction about data structure_i.pptxpoonamsngr
 
Chapter 1 Introduction to Data Structures and Algorithms.pdf
Chapter 1 Introduction to Data Structures and Algorithms.pdfChapter 1 Introduction to Data Structures and Algorithms.pdf
Chapter 1 Introduction to Data Structures and Algorithms.pdfAxmedcarb
 
Unit.1 Introduction to Data Structuresres
Unit.1 Introduction to Data StructuresresUnit.1 Introduction to Data Structuresres
Unit.1 Introduction to Data Structuresresamplopsurat
 
Data Structure Introduction chapter 1
Data Structure Introduction chapter 1Data Structure Introduction chapter 1
Data Structure Introduction chapter 1vasantiDutta1
 

Similar to Data structures and algorithm (20)

Data Structure Basics
Data Structure BasicsData Structure Basics
Data Structure Basics
 
1. Data structures introduction
1. Data structures introduction1. Data structures introduction
1. Data structures introduction
 
Data Structure # vpmp polytechnic
Data Structure # vpmp polytechnicData Structure # vpmp polytechnic
Data Structure # vpmp polytechnic
 
Iare ds lecture_notes_2
Iare ds lecture_notes_2Iare ds lecture_notes_2
Iare ds lecture_notes_2
 
Chapter 1( intro & overview)
Chapter 1( intro & overview)Chapter 1( intro & overview)
Chapter 1( intro & overview)
 
Introduction to Data Structure.pptx
Introduction to Data Structure.pptxIntroduction to Data Structure.pptx
Introduction to Data Structure.pptx
 
Preparing for BIT – IT2301 Database Management Systems 2001e
Preparing for BIT – IT2301 Database Management Systems 2001ePreparing for BIT – IT2301 Database Management Systems 2001e
Preparing for BIT – IT2301 Database Management Systems 2001e
 
Introduction to data structure ppt
Introduction to data structure pptIntroduction to data structure ppt
Introduction to data structure ppt
 
Introduction to DS.pptx
Introduction to DS.pptxIntroduction to DS.pptx
Introduction to DS.pptx
 
Lect 1-2 Zaheer Abbas
Lect 1-2 Zaheer AbbasLect 1-2 Zaheer Abbas
Lect 1-2 Zaheer Abbas
 
DS-UNIT 1 FINAL (2).pptx
DS-UNIT 1 FINAL (2).pptxDS-UNIT 1 FINAL (2).pptx
DS-UNIT 1 FINAL (2).pptx
 
Data Structures_Introduction
Data Structures_IntroductionData Structures_Introduction
Data Structures_Introduction
 
introduction about data structure_i.pptx
introduction about data structure_i.pptxintroduction about data structure_i.pptx
introduction about data structure_i.pptx
 
Lect 1-2
Lect 1-2Lect 1-2
Lect 1-2
 
Chapter 1 Introduction to Data Structures and Algorithms.pdf
Chapter 1 Introduction to Data Structures and Algorithms.pdfChapter 1 Introduction to Data Structures and Algorithms.pdf
Chapter 1 Introduction to Data Structures and Algorithms.pdf
 
Unit.1 Introduction to Data Structuresres
Unit.1 Introduction to Data StructuresresUnit.1 Introduction to Data Structuresres
Unit.1 Introduction to Data Structuresres
 
Data Structures & Algorithms
Data Structures & AlgorithmsData Structures & Algorithms
Data Structures & Algorithms
 
Data structure using c++
Data structure using c++Data structure using c++
Data structure using c++
 
UNIT II.docx
UNIT II.docxUNIT II.docx
UNIT II.docx
 
Data Structure Introduction chapter 1
Data Structure Introduction chapter 1Data Structure Introduction chapter 1
Data Structure Introduction chapter 1
 

More from Muhammad Aamir Rakhshani (20)

Tb writing book(1)
Tb writing book(1)Tb writing book(1)
Tb writing book(1)
 
Short reports
Short reportsShort reports
Short reports
 
Sentence structure
Sentence structureSentence structure
Sentence structure
 
Sentence structure
Sentence structureSentence structure
Sentence structure
 
Sentence structure
Sentence structureSentence structure
Sentence structure
 
Resume writing ppt
Resume writing ppt Resume writing ppt
Resume writing ppt
 
Report writing
Report writing Report writing
Report writing
 
Report writing (short version)
Report writing (short version)Report writing (short version)
Report writing (short version)
 
Oral presentation skills
Oral presentation skillsOral presentation skills
Oral presentation skills
 
Long reports
Long reportsLong reports
Long reports
 
Letterwriting types
Letterwriting typesLetterwriting types
Letterwriting types
 
Letter writing
Letter writingLetter writing
Letter writing
 
Letter writing(1)
Letter writing(1)Letter writing(1)
Letter writing(1)
 
Itroductions
ItroductionsItroductions
Itroductions
 
Guidelines
GuidelinesGuidelines
Guidelines
 
Grammar sentence-structure
Grammar sentence-structureGrammar sentence-structure
Grammar sentence-structure
 
Fs 10.2 how to write a cover letter
Fs 10.2 how to write a cover letterFs 10.2 how to write a cover letter
Fs 10.2 how to write a cover letter
 
Files 3-handouts lecture-12
Files 3-handouts lecture-12Files 3-handouts lecture-12
Files 3-handouts lecture-12
 
English 2(buiseness and technical writing)
English 2(buiseness and technical writing)English 2(buiseness and technical writing)
English 2(buiseness and technical writing)
 
English 2 slides
English 2 slidesEnglish 2 slides
English 2 slides
 

Recently uploaded

Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAndikSusilo4
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 

Recently uploaded (20)

Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 

Data structures and algorithm

  • 1. Lectures of Data Structures and Algorithm 08-Oct-13 Definition of Data Structure and Algorithm:The arrangement/manipulation of data by the compiler in computer memory. Types of Data Structure:1. Physical Data Structure 2. Logical Data Structure Examples of Data Structure:1. 2. 3. 4. 5. 6. Stat Queue => De-Queues Array Graph Sorting Tree *Physical DS:-. Physical memory of data by the translator. *Logical DS:Logical concept of data by the translator. 09-Oct-13 Types of Data Structure:1) Physical Data Structure:a) Linear Physical Data Structure(e.g. Array , Queue , Stat) b) Non-Linear Physical Data Structure(e.g. Link list, Tree, Graph) 2) Logical Data Structure:a) Linear Logical Data Structure b) Non-Linear Logical Data Structure Levels of Data Structure:Abstract Level Application Level Implementation Level 1) Abstract Level:In abstract way….. (sarsari tor per)
  • 2. Extra:2) Application Level:Array:Source code adding on a thing.  Homogeneous  Sequential order  Not Flexible (Fix) 3) Implementation Level:Executable code adding on a thing. Link-List:- Bubble Sort:-  NonHomogeneous  Non-Sequential  Flexible Step 1 2 2 2 2 2 2 2 2 Step 2 9 9 4 4 4 4 4 4 2 2 2 2 2 2 Step 3 4 4 9 1 1 1 1 1 4 1 1 1 1 1 2 1 1 2 1 2 1 2 1 2 1 2 1 2 Logical method:while(a[i]>a[i+1]){ //Swaping;a=b 1 1 1 9 5 5 5 5 5 5 5 5 9 6 6 6 6 6 6 6 6 9 7 7 7 7 7 7 7 7 9 8 8 8 8 8 8 8 8 9 1 4 4 4 4 4 5 5 5 5 5 5 6 6 6 6 6 6 7 7 7 7 7 7 8 8 8 8 8 8 9 9 9 9 9 9 4 4 4 4 4 4 4 5 5 5 5 5 5 5 6 6 6 6 6 6 6 7 7 7 7 7 7 7 8 8 8 8 8 8 8 9 9 9 9 9 9 9
  • 3. b=c c=a } Definition of Algorithm:Set of instructions is called Algorithm. OR Non-executable code is called Algorithm. It don’t have “;” or other statement ending words.