SlideShare a Scribd company logo
6
Most read
13
Most read
15
Most read
Linked list
A linked list is a sequence of data structures,
which are connected together via links.
Linked list
Linked list:
A linked list is a linear data structure, in which the elements are not
stored at contiguous memory locations. The elements in a linked list are
linked using pointers as shown in the below image:
Difference between arrays and Linked
list
 The size of the arrays is fixed
 In array elements are contiguous location
 In array, It’s costly to insert new elements
 In linked list random traversal is not allowed
 Extra memory space is required to store pointers in linked list
 Linked list performance is lower than array
Difference between arrays and Linked
list
Linked list
 Linked List contains a link element called first.
 Each node carries a data field(s) and a link field called next.
 Each node is linked with its next node using its next link.
 Last node carries a link as null to mark the end of the list.
Linked list
Types of Link list:
 Simple Linked List − Item navigation is forward only.
 Doubly Linked List − Items can be navigated forward and backward.
 Circular Linked List − Last item contains link of the first element as
next and the first element has a link to the last element as previous.
Simple Linked List
In simple linked list, navigation is possible only in one direction.
Operation on Link list:
 Insertion − Adds an element
 Deletion − Deletes an element
 Display − Displays the complete list.
 Search − Searches an element using the given key.
Simple Linked List
Insertion Operation:
Simple Linked List
Insertion Operation:
Simple Linked List
Insertion Operation:
Simple Linked List
Delete Operation:
Doubly Linked list
Doubly Linked List is a variation of Linked list in which navigation is
possible in both ways, either forward and backward easily as compared
to Single Linked List.
Doubly Linked list
Link − Each link of a linked list can store a data called an element.
Next − Each link of a linked list contains a link to the next link called
Next.
Prev − Each link of a linked list contains a link to the previous link called
Prev.
LinkedList − A Linked List contains the connection link to the first link
called First and to the last link called Last.
Doubly Linked List
Doubly Linked list
 Insertion − Adds an element at the beginning of the list.
 Deletion − Deletes an element at the beginning of the list.
 Insert Last − Adds an element at the end of the list.
 Delete Last − Deletes an element from the end of the list.
 Insert After − Adds an element after an item of the list.
 Delete − Deletes an element from the list using the key.
 Display forward − Displays the complete list in a forward manner.
 Display backward − Displays the complete list in a backward
manner.
Basic Operations on Doubly Linked List
Circular Linked list
Circular Linked List is a variation of Linked list in which the first element
points to the last element and the last element points to the first
element. Both Singly Linked List and Doubly Linked List can be made
into a circular linked list.
Circular linked list are two types:
Singly Linked List as Circular
Doubly Linked List as Circular
Circular Linked list
Basic Operation of Circular Linked List:
insert − Inserts an element at the start of the list.
delete − Deletes an element from the start of the list.
display − Displays the list.
Ad

Recommended

Blockchain in Supply Chain Management
Blockchain in Supply Chain Management
101 Blockchains
 
Graph in data structure
Graph in data structure
Abrish06
 
A presentation on prim's and kruskal's algorithm
A presentation on prim's and kruskal's algorithm
Gaurav Kolekar
 
Ppt on Linked list,stack,queue
Ppt on Linked list,stack,queue
Srajan Shukla
 
Data Encryption Standard (DES)
Data Encryption Standard (DES)
Haris Ahmed
 
DBMS Unit - 6 - Transaction Management
DBMS Unit - 6 - Transaction Management
Gyanmanjari Institute Of Technology
 
Singly & Circular Linked list
Singly & Circular Linked list
Khulna University of Engineering & Tecnology
 
linked list in data structure
linked list in data structure
shameen khan
 
Linked lists
Linked lists
SARITHA REDDY
 
Tree - Data Structure
Tree - Data Structure
Ashim Lamichhane
 
Data Structure and Algorithms Linked List
Data Structure and Algorithms Linked List
ManishPrajapati78
 
single linked list
single linked list
Sathasivam Rangasamy
 
Unit I - Evaluation of expression
Unit I - Evaluation of expression
DrkhanchanaR
 
Binary Tree in Data Structure
Binary Tree in Data Structure
Meghaj Mallick
 
Tree in data structure
Tree in data structure
ghhgj jhgh
 
Data Structures - Lecture 9 [Stack & Queue using Linked List]
Data Structures - Lecture 9 [Stack & Queue using Linked List]
Muhammad Hammad Waseem
 
Linked list
Linked list
KalaivaniKS1
 
linked lists in data structures
linked lists in data structures
DurgaDeviCbit
 
Doubly Linked List
Doubly Linked List
Ninad Mankar
 
Data Structures (CS8391)
Data Structures (CS8391)
Elavarasi K
 
Binary search tree(bst)
Binary search tree(bst)
Hossain Md Shakhawat
 
Stack data structure
Stack data structure
Tech_MX
 
B and B+ tree
B and B+ tree
Ashish Arun
 
Data structure & its types
Data structure & its types
Rameesha Sadaqat
 
Priority Queue in Data Structure
Priority Queue in Data Structure
Meghaj Mallick
 
BCA DATA STRUCTURES LINEAR ARRAYS MRS.SOWMYA JYOTHI
BCA DATA STRUCTURES LINEAR ARRAYS MRS.SOWMYA JYOTHI
Sowmya Jyothi
 
Stacks IN DATA STRUCTURES
Stacks IN DATA STRUCTURES
Sowmya Jyothi
 
Searching and sorting
Searching and sorting
PoojithaBollikonda
 
Data Structures and Algorithms - Lec 05.pptx
Data Structures and Algorithms - Lec 05.pptx
RameshaFernando2
 
Linked list
Linked list
MahammadAdil
 

More Related Content

What's hot (20)

Linked lists
Linked lists
SARITHA REDDY
 
Tree - Data Structure
Tree - Data Structure
Ashim Lamichhane
 
Data Structure and Algorithms Linked List
Data Structure and Algorithms Linked List
ManishPrajapati78
 
single linked list
single linked list
Sathasivam Rangasamy
 
Unit I - Evaluation of expression
Unit I - Evaluation of expression
DrkhanchanaR
 
Binary Tree in Data Structure
Binary Tree in Data Structure
Meghaj Mallick
 
Tree in data structure
Tree in data structure
ghhgj jhgh
 
Data Structures - Lecture 9 [Stack & Queue using Linked List]
Data Structures - Lecture 9 [Stack & Queue using Linked List]
Muhammad Hammad Waseem
 
Linked list
Linked list
KalaivaniKS1
 
linked lists in data structures
linked lists in data structures
DurgaDeviCbit
 
Doubly Linked List
Doubly Linked List
Ninad Mankar
 
Data Structures (CS8391)
Data Structures (CS8391)
Elavarasi K
 
Binary search tree(bst)
Binary search tree(bst)
Hossain Md Shakhawat
 
Stack data structure
Stack data structure
Tech_MX
 
B and B+ tree
B and B+ tree
Ashish Arun
 
Data structure & its types
Data structure & its types
Rameesha Sadaqat
 
Priority Queue in Data Structure
Priority Queue in Data Structure
Meghaj Mallick
 
BCA DATA STRUCTURES LINEAR ARRAYS MRS.SOWMYA JYOTHI
BCA DATA STRUCTURES LINEAR ARRAYS MRS.SOWMYA JYOTHI
Sowmya Jyothi
 
Stacks IN DATA STRUCTURES
Stacks IN DATA STRUCTURES
Sowmya Jyothi
 
Searching and sorting
Searching and sorting
PoojithaBollikonda
 
Data Structure and Algorithms Linked List
Data Structure and Algorithms Linked List
ManishPrajapati78
 
Unit I - Evaluation of expression
Unit I - Evaluation of expression
DrkhanchanaR
 
Binary Tree in Data Structure
Binary Tree in Data Structure
Meghaj Mallick
 
Tree in data structure
Tree in data structure
ghhgj jhgh
 
Data Structures - Lecture 9 [Stack & Queue using Linked List]
Data Structures - Lecture 9 [Stack & Queue using Linked List]
Muhammad Hammad Waseem
 
linked lists in data structures
linked lists in data structures
DurgaDeviCbit
 
Doubly Linked List
Doubly Linked List
Ninad Mankar
 
Data Structures (CS8391)
Data Structures (CS8391)
Elavarasi K
 
Stack data structure
Stack data structure
Tech_MX
 
Data structure & its types
Data structure & its types
Rameesha Sadaqat
 
Priority Queue in Data Structure
Priority Queue in Data Structure
Meghaj Mallick
 
BCA DATA STRUCTURES LINEAR ARRAYS MRS.SOWMYA JYOTHI
BCA DATA STRUCTURES LINEAR ARRAYS MRS.SOWMYA JYOTHI
Sowmya Jyothi
 
Stacks IN DATA STRUCTURES
Stacks IN DATA STRUCTURES
Sowmya Jyothi
 

Similar to linked list in Data Structure, Simple and Easy Tutorial (20)

Data Structures and Algorithms - Lec 05.pptx
Data Structures and Algorithms - Lec 05.pptx
RameshaFernando2
 
Linked list
Linked list
MahammadAdil
 
Link list
Link list
Didar Rashad
 
Link list
Link list
Didar Rashad
 
Linked list, Singly link list and its operations
Linked list, Singly link list and its operations
BackiyalakshmiVenkat
 
Linked List
Linked List
RaaviKapoor
 
ds-lecture-4-171012041008 (1).pdf
ds-lecture-4-171012041008 (1).pdf
KamranAli649587
 
Linked list in DS
Linked list in DS
chauhankapil
 
Unit 3 dsa LINKED LIST
Unit 3 dsa LINKED LIST
PUNE VIDYARTHI GRIHA'S COLLEGE OF ENGINEERING, NASHIK
 
Lecture 2b lists
Lecture 2b lists
Victor Palmar
 
Linked List
Linked List
Md gulam sarwar
 
Data Structures-UNIT Four_Linked_List.pptx
Data Structures-UNIT Four_Linked_List.pptx
shilpar780389
 
CH4.pptx
CH4.pptx
mohamedOsmaanFG
 
Linked List
Linked List
BHARATH KUMAR
 
Link list assi
Link list assi
PATILPANKAJ106130
 
Linked List Representation of a Linked List.pptx
Linked List Representation of a Linked List.pptx
AAUsH2
 
Linked lists linked lists vs Arrays.pptx
Linked lists linked lists vs Arrays.pptx
Sahar160629
 
Linked list (1).pptx
Linked list (1).pptx
rajveersingh643731
 
Data-Structures-and-Algorithms-on-Linked-Lists (1).pptx
Data-Structures-and-Algorithms-on-Linked-Lists (1).pptx
Praveen156918
 
Linked List
Linked List
Keshav Vaswani
 
Ad

Recently uploaded (20)

Lesson-3_Program-Outcomes-and-Student-Learning-Outcomes_For-Students.pdf
Lesson-3_Program-Outcomes-and-Student-Learning-Outcomes_For-Students.pdf
SarahMaeDuallo
 
YEAP !NOT WHAT YOU THINK aakshdjdncnkenfj
YEAP !NOT WHAT YOU THINK aakshdjdncnkenfj
payalmistryb
 
最新版美国加利福尼亚大学旧金山法学院毕业证(UCLawSF毕业证书)定制
最新版美国加利福尼亚大学旧金山法学院毕业证(UCLawSF毕业证书)定制
taqyea
 
Artigo - Playing to Win.planejamento docx
Artigo - Playing to Win.planejamento docx
KellyXavier15
 
Presentation by Tariq & Mohammed (1).pptx
Presentation by Tariq & Mohammed (1).pptx
AbooddSandoqaa
 
The Influence off Flexible Work Policies
The Influence off Flexible Work Policies
sales480687
 
Data Visualisation in data science for students
Data Visualisation in data science for students
confidenceascend
 
Shifting Focus on AI: How it Can Make a Positive Difference
Shifting Focus on AI: How it Can Make a Positive Difference
1508 A/S
 
@Reset-Password.pptx presentakh;kenvtion
@Reset-Password.pptx presentakh;kenvtion
MarkLariosa1
 
美国毕业证范本中华盛顿大学学位证书CWU学生卡购买
美国毕业证范本中华盛顿大学学位证书CWU学生卡购买
Taqyea
 
Measurecamp Copenhagen - Consent Context
Measurecamp Copenhagen - Consent Context
Human37
 
NVIDIA Triton Inference Server, a game-changing platform for deploying AI mod...
NVIDIA Triton Inference Server, a game-changing platform for deploying AI mod...
Tamanna36
 
Statistics-and-Computer-Tools-for-Analyzing-of-Assessment-Data.pptx
Statistics-and-Computer-Tools-for-Analyzing-of-Assessment-Data.pptx
pelaezmaryjoy90
 
11_L2_Defects_and_Trouble_Shooting_2014[1].pdf
11_L2_Defects_and_Trouble_Shooting_2014[1].pdf
gun3awan88
 
最新版美国芝加哥大学毕业证(UChicago毕业证书)原版定制
最新版美国芝加哥大学毕业证(UChicago毕业证书)原版定制
taqyea
 
最新版美国威斯康星大学河城分校毕业证(UWRF毕业证书)原版定制
最新版美国威斯康星大学河城分校毕业证(UWRF毕业证书)原版定制
taqyea
 
Starbucks in the Indian market through its joint venture.
Starbucks in the Indian market through its joint venture.
sales480687
 
Crafting-Research-Recommendations Grade 12.pptx
Crafting-Research-Recommendations Grade 12.pptx
DaryllWhere
 
MRI Pulse Sequence in radiology physics.pptx
MRI Pulse Sequence in radiology physics.pptx
BelaynehBishaw
 
Prescriptive Process Monitoring Under Uncertainty and Resource Constraints: A...
Prescriptive Process Monitoring Under Uncertainty and Resource Constraints: A...
Mahmoud Shoush
 
Lesson-3_Program-Outcomes-and-Student-Learning-Outcomes_For-Students.pdf
Lesson-3_Program-Outcomes-and-Student-Learning-Outcomes_For-Students.pdf
SarahMaeDuallo
 
YEAP !NOT WHAT YOU THINK aakshdjdncnkenfj
YEAP !NOT WHAT YOU THINK aakshdjdncnkenfj
payalmistryb
 
最新版美国加利福尼亚大学旧金山法学院毕业证(UCLawSF毕业证书)定制
最新版美国加利福尼亚大学旧金山法学院毕业证(UCLawSF毕业证书)定制
taqyea
 
Artigo - Playing to Win.planejamento docx
Artigo - Playing to Win.planejamento docx
KellyXavier15
 
Presentation by Tariq & Mohammed (1).pptx
Presentation by Tariq & Mohammed (1).pptx
AbooddSandoqaa
 
The Influence off Flexible Work Policies
The Influence off Flexible Work Policies
sales480687
 
Data Visualisation in data science for students
Data Visualisation in data science for students
confidenceascend
 
Shifting Focus on AI: How it Can Make a Positive Difference
Shifting Focus on AI: How it Can Make a Positive Difference
1508 A/S
 
@Reset-Password.pptx presentakh;kenvtion
@Reset-Password.pptx presentakh;kenvtion
MarkLariosa1
 
美国毕业证范本中华盛顿大学学位证书CWU学生卡购买
美国毕业证范本中华盛顿大学学位证书CWU学生卡购买
Taqyea
 
Measurecamp Copenhagen - Consent Context
Measurecamp Copenhagen - Consent Context
Human37
 
NVIDIA Triton Inference Server, a game-changing platform for deploying AI mod...
NVIDIA Triton Inference Server, a game-changing platform for deploying AI mod...
Tamanna36
 
Statistics-and-Computer-Tools-for-Analyzing-of-Assessment-Data.pptx
Statistics-and-Computer-Tools-for-Analyzing-of-Assessment-Data.pptx
pelaezmaryjoy90
 
11_L2_Defects_and_Trouble_Shooting_2014[1].pdf
11_L2_Defects_and_Trouble_Shooting_2014[1].pdf
gun3awan88
 
最新版美国芝加哥大学毕业证(UChicago毕业证书)原版定制
最新版美国芝加哥大学毕业证(UChicago毕业证书)原版定制
taqyea
 
最新版美国威斯康星大学河城分校毕业证(UWRF毕业证书)原版定制
最新版美国威斯康星大学河城分校毕业证(UWRF毕业证书)原版定制
taqyea
 
Starbucks in the Indian market through its joint venture.
Starbucks in the Indian market through its joint venture.
sales480687
 
Crafting-Research-Recommendations Grade 12.pptx
Crafting-Research-Recommendations Grade 12.pptx
DaryllWhere
 
MRI Pulse Sequence in radiology physics.pptx
MRI Pulse Sequence in radiology physics.pptx
BelaynehBishaw
 
Prescriptive Process Monitoring Under Uncertainty and Resource Constraints: A...
Prescriptive Process Monitoring Under Uncertainty and Resource Constraints: A...
Mahmoud Shoush
 
Ad

linked list in Data Structure, Simple and Easy Tutorial

  • 1. Linked list A linked list is a sequence of data structures, which are connected together via links.
  • 2. Linked list Linked list: A linked list is a linear data structure, in which the elements are not stored at contiguous memory locations. The elements in a linked list are linked using pointers as shown in the below image:
  • 3. Difference between arrays and Linked list  The size of the arrays is fixed  In array elements are contiguous location  In array, It’s costly to insert new elements  In linked list random traversal is not allowed  Extra memory space is required to store pointers in linked list  Linked list performance is lower than array
  • 4. Difference between arrays and Linked list
  • 5. Linked list  Linked List contains a link element called first.  Each node carries a data field(s) and a link field called next.  Each node is linked with its next node using its next link.  Last node carries a link as null to mark the end of the list.
  • 6. Linked list Types of Link list:  Simple Linked List − Item navigation is forward only.  Doubly Linked List − Items can be navigated forward and backward.  Circular Linked List − Last item contains link of the first element as next and the first element has a link to the last element as previous.
  • 7. Simple Linked List In simple linked list, navigation is possible only in one direction. Operation on Link list:  Insertion − Adds an element  Deletion − Deletes an element  Display − Displays the complete list.  Search − Searches an element using the given key.
  • 12. Doubly Linked list Doubly Linked List is a variation of Linked list in which navigation is possible in both ways, either forward and backward easily as compared to Single Linked List.
  • 13. Doubly Linked list Link − Each link of a linked list can store a data called an element. Next − Each link of a linked list contains a link to the next link called Next. Prev − Each link of a linked list contains a link to the previous link called Prev. LinkedList − A Linked List contains the connection link to the first link called First and to the last link called Last. Doubly Linked List
  • 14. Doubly Linked list  Insertion − Adds an element at the beginning of the list.  Deletion − Deletes an element at the beginning of the list.  Insert Last − Adds an element at the end of the list.  Delete Last − Deletes an element from the end of the list.  Insert After − Adds an element after an item of the list.  Delete − Deletes an element from the list using the key.  Display forward − Displays the complete list in a forward manner.  Display backward − Displays the complete list in a backward manner. Basic Operations on Doubly Linked List
  • 15. Circular Linked list Circular Linked List is a variation of Linked list in which the first element points to the last element and the last element points to the first element. Both Singly Linked List and Doubly Linked List can be made into a circular linked list. Circular linked list are two types: Singly Linked List as Circular Doubly Linked List as Circular
  • 16. Circular Linked list Basic Operation of Circular Linked List: insert − Inserts an element at the start of the list. delete − Deletes an element from the start of the list. display − Displays the list.