SlideShare a Scribd company logo
தரவ கடடடமமபடப | இரடடமட மறடறமட வடடடமமன
இமணகடகபடபடடட வரரமச
பப.மகமலடடசமர
Data Structures | Double and Circular
Linked List
Data Structures -
Double and Circular Linked List
Mahalakshmi P
What is Double Linked List?
Double linked list is a sequence of elements in which
every element has links to its previous element and
next element in the sequence.
Difference
● single linked list
● every node has a link to
its next node in the
sequence.
● we can traverse from one
node to another node
only in one direction
● we can not traverse back
● double linked list
● every node has a link to
its previous node and
next node.
● So, we can traverse
forward by using the
next field and can
traverse backward by
using the previous field
Node Structure
Important Points to be Remembered
● In double linked list, the first node must be always
pointed by head.
● Always the previous field of the first node must be
NULL.
● Always the next field of the last node must be
NULL.
Operations
At Beginning of the list
● Insertion At End of the list
At Specific location in the
list
Operation
At Beginning of the list
At End of the list
At Specific location in the
list
Deletion
Applications/Uses of doubly linked list
in real life
● Doubly linked list can be used in navigation systems
where both front and back navigation is required.
● It is used by browsers to implement backward and
forward navigation of visited web pages i.e. back and
forward button.
● It is also used by various application to implement Undo
and Redo functionality.
● It can also be used to represent deck of cards in games.
● It is also used to represent various states of a game.
Circular Linked List
● A circular linked list is basically a linear linked list
that may be singly or doubly.
● The only difference is that there is no any NULL
value terminating the list.
● every node points to the next node and last node
points to the first node which forms circle.
● whole node can be traversed from any node.
Basic structure of Circular linked list
Singly Circular linked list
Doubly Circular Linked List
●Applications/Uses of Circular linked
list in real life
● Circular lists are used in applications where the
entire list is accessed one-by-one in a loop.
Example: Operating systems may use it to switch
between various running applications in a circular
loop.
● Multiplayer games uses circular list to swap between
players in a loop.
Reference
● https://codeforwin.org/2015/11/circular-linked-list-d
ata-structure.html
● http://btechsmartclass.com/data_structures/circular-l
inked-list.html

More Related Content

What's hot

Data Structures- Part7 linked lists
Data Structures- Part7 linked listsData Structures- Part7 linked lists
Data Structures- Part7 linked lists
Abdullah Al-hazmy
 
Binary Search Tree in Data Structure
Binary Search Tree in Data StructureBinary Search Tree in Data Structure
Binary Search Tree in Data Structure
Dharita Chokshi
 
Linked List, Types of Linked LIst, Various Operations, Applications of Linked...
Linked List, Types of Linked LIst, Various Operations, Applications of Linked...Linked List, Types of Linked LIst, Various Operations, Applications of Linked...
Linked List, Types of Linked LIst, Various Operations, Applications of Linked...
Balwant Gorad
 
Circular link list.ppt
Circular link list.pptCircular link list.ppt
Circular link list.ppt
Tirthika Bandi
 
Linked List
Linked ListLinked List
Linked List
Ashim Lamichhane
 
Doubly linked list (animated)
Doubly linked list (animated)Doubly linked list (animated)
Doubly linked list (animated)
DivyeshKumar Jagatiya
 
Context free grammar
Context free grammarContext free grammar
Context free grammar
Ratnakar Mikkili
 
Binary Search
Binary SearchBinary Search
Binary Search
kunj desai
 
ER Modeling and Introduction to RDBMS
ER Modeling and Introduction to RDBMSER Modeling and Introduction to RDBMS
ER Modeling and Introduction to RDBMS
Rubal Sagwal
 
Registers
RegistersRegisters
Registers
UMARHASSAN31
 
Graph in data structure
Graph in data structureGraph in data structure
Graph in data structure
Abrish06
 
Half adder & full adder
Half adder & full adderHalf adder & full adder
Half adder & full adder
Gaditek
 
Bucket sort
Bucket sortBucket sort
Linked List
Linked ListLinked List
Linked List
CHANDAN KUMAR
 
Linked list
Linked listLinked list
Linked list
KalaivaniKS1
 
Singly Linked List & Data Structure
Singly Linked List & Data StructureSingly Linked List & Data Structure
Sorting Algorithms
Sorting AlgorithmsSorting Algorithms
Sorting Algorithms
Pranay Neema
 
Skip lists (Advance Data structure)
Skip lists (Advance Data structure)Skip lists (Advance Data structure)
Skip lists (Advance Data structure)
Shubham Shukla
 
header, circular and two way linked lists
header, circular and two way linked listsheader, circular and two way linked lists
header, circular and two way linked lists
student
 
Graph data structure
Graph data structureGraph data structure
Graph data structure
Tech_MX
 

What's hot (20)

Data Structures- Part7 linked lists
Data Structures- Part7 linked listsData Structures- Part7 linked lists
Data Structures- Part7 linked lists
 
Binary Search Tree in Data Structure
Binary Search Tree in Data StructureBinary Search Tree in Data Structure
Binary Search Tree in Data Structure
 
Linked List, Types of Linked LIst, Various Operations, Applications of Linked...
Linked List, Types of Linked LIst, Various Operations, Applications of Linked...Linked List, Types of Linked LIst, Various Operations, Applications of Linked...
Linked List, Types of Linked LIst, Various Operations, Applications of Linked...
 
Circular link list.ppt
Circular link list.pptCircular link list.ppt
Circular link list.ppt
 
Linked List
Linked ListLinked List
Linked List
 
Doubly linked list (animated)
Doubly linked list (animated)Doubly linked list (animated)
Doubly linked list (animated)
 
Context free grammar
Context free grammarContext free grammar
Context free grammar
 
Binary Search
Binary SearchBinary Search
Binary Search
 
ER Modeling and Introduction to RDBMS
ER Modeling and Introduction to RDBMSER Modeling and Introduction to RDBMS
ER Modeling and Introduction to RDBMS
 
Registers
RegistersRegisters
Registers
 
Graph in data structure
Graph in data structureGraph in data structure
Graph in data structure
 
Half adder & full adder
Half adder & full adderHalf adder & full adder
Half adder & full adder
 
Bucket sort
Bucket sortBucket sort
Bucket sort
 
Linked List
Linked ListLinked List
Linked List
 
Linked list
Linked listLinked list
Linked list
 
Singly Linked List & Data Structure
Singly Linked List & Data StructureSingly Linked List & Data Structure
Singly Linked List & Data Structure
 
Sorting Algorithms
Sorting AlgorithmsSorting Algorithms
Sorting Algorithms
 
Skip lists (Advance Data structure)
Skip lists (Advance Data structure)Skip lists (Advance Data structure)
Skip lists (Advance Data structure)
 
header, circular and two way linked lists
header, circular and two way linked listsheader, circular and two way linked lists
header, circular and two way linked lists
 
Graph data structure
Graph data structureGraph data structure
Graph data structure
 

More from MAHALAKSHMI P

Python an-intro youtube-livestream-day4
Python an-intro youtube-livestream-day4Python an-intro youtube-livestream-day4
Python an-intro youtube-livestream-day4
MAHALAKSHMI P
 
Python an-intro youtube-livestream-day3
Python an-intro youtube-livestream-day3Python an-intro youtube-livestream-day3
Python an-intro youtube-livestream-day3
MAHALAKSHMI P
 
Python an-intro youtube-livestream-day2
Python an-intro youtube-livestream-day2Python an-intro youtube-livestream-day2
Python an-intro youtube-livestream-day2
MAHALAKSHMI P
 
Python an-intro youtube-livestream-day1
Python an-intro youtube-livestream-day1Python an-intro youtube-livestream-day1
Python an-intro youtube-livestream-day1
MAHALAKSHMI P
 
linked list operations in data structures
linked list operations in data structureslinked list operations in data structures
linked list operations in data structures
MAHALAKSHMI P
 
singly linked_list
singly linked_listsingly linked_list
singly linked_list
MAHALAKSHMI P
 
sparse matrix in data structure
sparse matrix in data structuresparse matrix in data structure
sparse matrix in data structure
MAHALAKSHMI P
 
arrays in data structures
arrays in data structuresarrays in data structures
arrays in data structures
MAHALAKSHMI P
 
Data structures and algorithms
Data structures and algorithmsData structures and algorithms
Data structures and algorithms
MAHALAKSHMI P
 
Data structures- introduction1
Data structures-  introduction1Data structures-  introduction1
Data structures- introduction1
MAHALAKSHMI P
 
Python_in_Detail
Python_in_DetailPython_in_Detail
Python_in_Detail
MAHALAKSHMI P
 
Sex education,பாலியல் கல்வி ,paaliyal kalvi,good touch bad touch
Sex education,பாலியல் கல்வி ,paaliyal kalvi,good touch bad touchSex education,பாலியல் கல்வி ,paaliyal kalvi,good touch bad touch
Sex education,பாலியல் கல்வி ,paaliyal kalvi,good touch bad touch
MAHALAKSHMI P
 
Seminar on sunday
Seminar on sundaySeminar on sunday
Seminar on sunday
MAHALAKSHMI P
 

More from MAHALAKSHMI P (13)

Python an-intro youtube-livestream-day4
Python an-intro youtube-livestream-day4Python an-intro youtube-livestream-day4
Python an-intro youtube-livestream-day4
 
Python an-intro youtube-livestream-day3
Python an-intro youtube-livestream-day3Python an-intro youtube-livestream-day3
Python an-intro youtube-livestream-day3
 
Python an-intro youtube-livestream-day2
Python an-intro youtube-livestream-day2Python an-intro youtube-livestream-day2
Python an-intro youtube-livestream-day2
 
Python an-intro youtube-livestream-day1
Python an-intro youtube-livestream-day1Python an-intro youtube-livestream-day1
Python an-intro youtube-livestream-day1
 
linked list operations in data structures
linked list operations in data structureslinked list operations in data structures
linked list operations in data structures
 
singly linked_list
singly linked_listsingly linked_list
singly linked_list
 
sparse matrix in data structure
sparse matrix in data structuresparse matrix in data structure
sparse matrix in data structure
 
arrays in data structures
arrays in data structuresarrays in data structures
arrays in data structures
 
Data structures and algorithms
Data structures and algorithmsData structures and algorithms
Data structures and algorithms
 
Data structures- introduction1
Data structures-  introduction1Data structures-  introduction1
Data structures- introduction1
 
Python_in_Detail
Python_in_DetailPython_in_Detail
Python_in_Detail
 
Sex education,பாலியல் கல்வி ,paaliyal kalvi,good touch bad touch
Sex education,பாலியல் கல்வி ,paaliyal kalvi,good touch bad touchSex education,பாலியல் கல்வி ,paaliyal kalvi,good touch bad touch
Sex education,பாலியல் கல்வி ,paaliyal kalvi,good touch bad touch
 
Seminar on sunday
Seminar on sundaySeminar on sunday
Seminar on sunday
 

Recently uploaded

Exception Handling notes in java exception
Exception Handling notes in java exceptionException Handling notes in java exception
Exception Handling notes in java exception
Ratnakar Mikkili
 
Heap Sort (SS).ppt FOR ENGINEERING GRADUATES, BCA, MCA, MTECH, BSC STUDENTS
Heap Sort (SS).ppt FOR ENGINEERING GRADUATES, BCA, MCA, MTECH, BSC STUDENTSHeap Sort (SS).ppt FOR ENGINEERING GRADUATES, BCA, MCA, MTECH, BSC STUDENTS
Heap Sort (SS).ppt FOR ENGINEERING GRADUATES, BCA, MCA, MTECH, BSC STUDENTS
Soumen Santra
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
thanhdowork
 
PPT on GRP pipes manufacturing and testing
PPT on GRP pipes manufacturing and testingPPT on GRP pipes manufacturing and testing
PPT on GRP pipes manufacturing and testing
anoopmanoharan2
 
一比一原版(UC Berkeley毕业证)加利福尼亚大学|伯克利分校毕业证成绩单专业办理
一比一原版(UC Berkeley毕业证)加利福尼亚大学|伯克利分校毕业证成绩单专业办理一比一原版(UC Berkeley毕业证)加利福尼亚大学|伯克利分校毕业证成绩单专业办理
一比一原版(UC Berkeley毕业证)加利福尼亚大学|伯克利分校毕业证成绩单专业办理
skuxot
 
basic-wireline-operations-course-mahmoud-f-radwan.pdf
basic-wireline-operations-course-mahmoud-f-radwan.pdfbasic-wireline-operations-course-mahmoud-f-radwan.pdf
basic-wireline-operations-course-mahmoud-f-radwan.pdf
NidhalKahouli2
 
5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...
5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...
5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...
ihlasbinance2003
 
Generative AI leverages algorithms to create various forms of content
Generative AI leverages algorithms to create various forms of contentGenerative AI leverages algorithms to create various forms of content
Generative AI leverages algorithms to create various forms of content
Hitesh Mohapatra
 
Literature Review Basics and Understanding Reference Management.pptx
Literature Review Basics and Understanding Reference Management.pptxLiterature Review Basics and Understanding Reference Management.pptx
Literature Review Basics and Understanding Reference Management.pptx
Dr Ramhari Poudyal
 
Swimming pool mechanical components design.pptx
Swimming pool  mechanical components design.pptxSwimming pool  mechanical components design.pptx
Swimming pool mechanical components design.pptx
yokeleetan1
 
Hierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power SystemHierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power System
Kerry Sado
 
spirit beverages ppt without graphics.pptx
spirit beverages ppt without graphics.pptxspirit beverages ppt without graphics.pptx
spirit beverages ppt without graphics.pptx
Madan Karki
 
PROJECT FORMAT FOR EVS AMITY UNIVERSITY GWALIOR.ppt
PROJECT FORMAT FOR EVS AMITY UNIVERSITY GWALIOR.pptPROJECT FORMAT FOR EVS AMITY UNIVERSITY GWALIOR.ppt
PROJECT FORMAT FOR EVS AMITY UNIVERSITY GWALIOR.ppt
bhadouriyakaku
 
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&BDesign and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Sreedhar Chowdam
 
Building Electrical System Design & Installation
Building Electrical System Design & InstallationBuilding Electrical System Design & Installation
Building Electrical System Design & Installation
symbo111
 
DEEP LEARNING FOR SMART GRID INTRUSION DETECTION: A HYBRID CNN-LSTM-BASED MODEL
DEEP LEARNING FOR SMART GRID INTRUSION DETECTION: A HYBRID CNN-LSTM-BASED MODELDEEP LEARNING FOR SMART GRID INTRUSION DETECTION: A HYBRID CNN-LSTM-BASED MODEL
DEEP LEARNING FOR SMART GRID INTRUSION DETECTION: A HYBRID CNN-LSTM-BASED MODEL
gerogepatton
 
New techniques for characterising damage in rock slopes.pdf
New techniques for characterising damage in rock slopes.pdfNew techniques for characterising damage in rock slopes.pdf
New techniques for characterising damage in rock slopes.pdf
wisnuprabawa3
 
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
obonagu
 
Recycled Concrete Aggregate in Construction Part III
Recycled Concrete Aggregate in Construction Part IIIRecycled Concrete Aggregate in Construction Part III
Recycled Concrete Aggregate in Construction Part III
Aditya Rajan Patra
 
Advanced control scheme of doubly fed induction generator for wind turbine us...
Advanced control scheme of doubly fed induction generator for wind turbine us...Advanced control scheme of doubly fed induction generator for wind turbine us...
Advanced control scheme of doubly fed induction generator for wind turbine us...
IJECEIAES
 

Recently uploaded (20)

Exception Handling notes in java exception
Exception Handling notes in java exceptionException Handling notes in java exception
Exception Handling notes in java exception
 
Heap Sort (SS).ppt FOR ENGINEERING GRADUATES, BCA, MCA, MTECH, BSC STUDENTS
Heap Sort (SS).ppt FOR ENGINEERING GRADUATES, BCA, MCA, MTECH, BSC STUDENTSHeap Sort (SS).ppt FOR ENGINEERING GRADUATES, BCA, MCA, MTECH, BSC STUDENTS
Heap Sort (SS).ppt FOR ENGINEERING GRADUATES, BCA, MCA, MTECH, BSC STUDENTS
 
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
RAT: Retrieval Augmented Thoughts Elicit Context-Aware Reasoning in Long-Hori...
 
PPT on GRP pipes manufacturing and testing
PPT on GRP pipes manufacturing and testingPPT on GRP pipes manufacturing and testing
PPT on GRP pipes manufacturing and testing
 
一比一原版(UC Berkeley毕业证)加利福尼亚大学|伯克利分校毕业证成绩单专业办理
一比一原版(UC Berkeley毕业证)加利福尼亚大学|伯克利分校毕业证成绩单专业办理一比一原版(UC Berkeley毕业证)加利福尼亚大学|伯克利分校毕业证成绩单专业办理
一比一原版(UC Berkeley毕业证)加利福尼亚大学|伯克利分校毕业证成绩单专业办理
 
basic-wireline-operations-course-mahmoud-f-radwan.pdf
basic-wireline-operations-course-mahmoud-f-radwan.pdfbasic-wireline-operations-course-mahmoud-f-radwan.pdf
basic-wireline-operations-course-mahmoud-f-radwan.pdf
 
5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...
5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...
5214-1693458878915-Unit 6 2023 to 2024 academic year assignment (AutoRecovere...
 
Generative AI leverages algorithms to create various forms of content
Generative AI leverages algorithms to create various forms of contentGenerative AI leverages algorithms to create various forms of content
Generative AI leverages algorithms to create various forms of content
 
Literature Review Basics and Understanding Reference Management.pptx
Literature Review Basics and Understanding Reference Management.pptxLiterature Review Basics and Understanding Reference Management.pptx
Literature Review Basics and Understanding Reference Management.pptx
 
Swimming pool mechanical components design.pptx
Swimming pool  mechanical components design.pptxSwimming pool  mechanical components design.pptx
Swimming pool mechanical components design.pptx
 
Hierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power SystemHierarchical Digital Twin of a Naval Power System
Hierarchical Digital Twin of a Naval Power System
 
spirit beverages ppt without graphics.pptx
spirit beverages ppt without graphics.pptxspirit beverages ppt without graphics.pptx
spirit beverages ppt without graphics.pptx
 
PROJECT FORMAT FOR EVS AMITY UNIVERSITY GWALIOR.ppt
PROJECT FORMAT FOR EVS AMITY UNIVERSITY GWALIOR.pptPROJECT FORMAT FOR EVS AMITY UNIVERSITY GWALIOR.ppt
PROJECT FORMAT FOR EVS AMITY UNIVERSITY GWALIOR.ppt
 
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&BDesign and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
Design and Analysis of Algorithms-DP,Backtracking,Graphs,B&B
 
Building Electrical System Design & Installation
Building Electrical System Design & InstallationBuilding Electrical System Design & Installation
Building Electrical System Design & Installation
 
DEEP LEARNING FOR SMART GRID INTRUSION DETECTION: A HYBRID CNN-LSTM-BASED MODEL
DEEP LEARNING FOR SMART GRID INTRUSION DETECTION: A HYBRID CNN-LSTM-BASED MODELDEEP LEARNING FOR SMART GRID INTRUSION DETECTION: A HYBRID CNN-LSTM-BASED MODEL
DEEP LEARNING FOR SMART GRID INTRUSION DETECTION: A HYBRID CNN-LSTM-BASED MODEL
 
New techniques for characterising damage in rock slopes.pdf
New techniques for characterising damage in rock slopes.pdfNew techniques for characterising damage in rock slopes.pdf
New techniques for characterising damage in rock slopes.pdf
 
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
在线办理(ANU毕业证书)澳洲国立大学毕业证录取通知书一模一样
 
Recycled Concrete Aggregate in Construction Part III
Recycled Concrete Aggregate in Construction Part IIIRecycled Concrete Aggregate in Construction Part III
Recycled Concrete Aggregate in Construction Part III
 
Advanced control scheme of doubly fed induction generator for wind turbine us...
Advanced control scheme of doubly fed induction generator for wind turbine us...Advanced control scheme of doubly fed induction generator for wind turbine us...
Advanced control scheme of doubly fed induction generator for wind turbine us...
 

double linked list

  • 1. தரவ கடடடமமபடப | இரடடமட மறடறமட வடடடமமன இமணகடகபடபடடட வரரமச பப.மகமலடடசமர Data Structures | Double and Circular Linked List
  • 2. Data Structures - Double and Circular Linked List Mahalakshmi P
  • 3. What is Double Linked List? Double linked list is a sequence of elements in which every element has links to its previous element and next element in the sequence.
  • 4. Difference ● single linked list ● every node has a link to its next node in the sequence. ● we can traverse from one node to another node only in one direction ● we can not traverse back ● double linked list ● every node has a link to its previous node and next node. ● So, we can traverse forward by using the next field and can traverse backward by using the previous field
  • 6. Important Points to be Remembered ● In double linked list, the first node must be always pointed by head. ● Always the previous field of the first node must be NULL. ● Always the next field of the last node must be NULL.
  • 7. Operations At Beginning of the list ● Insertion At End of the list At Specific location in the list
  • 8. Operation At Beginning of the list At End of the list At Specific location in the list Deletion
  • 9. Applications/Uses of doubly linked list in real life ● Doubly linked list can be used in navigation systems where both front and back navigation is required. ● It is used by browsers to implement backward and forward navigation of visited web pages i.e. back and forward button. ● It is also used by various application to implement Undo and Redo functionality. ● It can also be used to represent deck of cards in games. ● It is also used to represent various states of a game.
  • 10. Circular Linked List ● A circular linked list is basically a linear linked list that may be singly or doubly. ● The only difference is that there is no any NULL value terminating the list. ● every node points to the next node and last node points to the first node which forms circle. ● whole node can be traversed from any node.
  • 11. Basic structure of Circular linked list Singly Circular linked list Doubly Circular Linked List
  • 12. ●Applications/Uses of Circular linked list in real life ● Circular lists are used in applications where the entire list is accessed one-by-one in a loop. Example: Operating systems may use it to switch between various running applications in a circular loop. ● Multiplayer games uses circular list to swap between players in a loop.