SlideShare a Scribd company logo
Linked Lists
DATA TYPES AND STRUCTURES
Linked Lists
 A linked list is a set of items which are arranged in an
sequential order, like an array, but each item links to the next
item in the list.
 Linked lists have advantages and disadvantages:
Advantages of Linked Lists
 No fixed size: the list can expand or reduce when the program
is run.
 Linked lists are flexible: the order within the lists can be
changed without having to move data (just the links are
moved).
 Memory efficient than an array: only needs to be the size
required for the number of items stored, not as large as the
possible number of items to be stored.
Disadvantages of Linked Lists
 Cannot use an index within a linked list to identify a particular
item. To find a specific item you need to go through the list
from beginning to end.
Inserting and Adding Items
 Inserting an item between two present items within a list can be achieved
by changing the link of the pointer to point to the inserted item.
 Adding an item to the end of the list can be done by redirecting the last
link to the new item and linking the new item to NUL .
 Adding an item to the beginning of the list can be done by redirecting the
Head of the list to the new item and pointing its link to the formal first
item.
Deleting Items
 Deleting an item from a list would be achieved by changing the link from
the item before to the item after, bypassing the item which is no longer
required.

More Related Content

PPTX
Standard Algorithms
PPTX
Applied systems 1 vocabulary
PPTX
Applied systems 1 vocabulary
PPTX
Create table relationships
PPTX
microsoft excel
PPTX
Data structures
PPTX
ICT: SPREADSHEETS (MICROSOFT EXCEL)
PDF
CCPRO 2016 Power Presentation
Standard Algorithms
Applied systems 1 vocabulary
Applied systems 1 vocabulary
Create table relationships
microsoft excel
Data structures
ICT: SPREADSHEETS (MICROSOFT EXCEL)
CCPRO 2016 Power Presentation

What's hot (19)

DOC
Ash hlt 540 week 3 assignment 1 coyne and messina articles
PPTX
Using microsoft excel
PPT
Linked list in DS
PPTX
Exceeeeeeeeeelsuperogriginal
PPTX
Excel
PDF
Spss vs excel which one is the best tool for statistics
PPTX
Ms office excel
PPT
Spreadsheet 1
PPTX
Digital tools
POTX
Excel Presentation
PPT
PPTX
MS Sql Server: Reporting manipulating data
PPTX
Excel users: An end to the agonizing tracing of formula precedents & dependen...
PDF
Excel Formula For A List Of Dates
PPTX
microsoft excel
PPT
Excel 2007 Unit M
PPTX
AVL Tree
Ash hlt 540 week 3 assignment 1 coyne and messina articles
Using microsoft excel
Linked list in DS
Exceeeeeeeeeelsuperogriginal
Excel
Spss vs excel which one is the best tool for statistics
Ms office excel
Spreadsheet 1
Digital tools
Excel Presentation
MS Sql Server: Reporting manipulating data
Excel users: An end to the agonizing tracing of formula precedents & dependen...
Excel Formula For A List Of Dates
microsoft excel
Excel 2007 Unit M
AVL Tree
Ad

Viewers also liked (14)

PPTX
Software Development Process
PPTX
Units of storage
PPTX
Binary numbers
PPT
Joke task
PPTX
Linked Lists
PPTX
Quadrilaterals
PPTX
Web Development
PPTX
Audio and Video
PPTX
Quadrilaterals [autosaved]
PPTX
Project management
PPTX
Programming Paradigm
PPTX
Legal, Ethical, Environmental, Economic and Social Implications
PDF
Подольская Федерация Футбола в 2014 году
DOCX
CV of Kazi Monjurul Alam
Software Development Process
Units of storage
Binary numbers
Joke task
Linked Lists
Quadrilaterals
Web Development
Audio and Video
Quadrilaterals [autosaved]
Project management
Programming Paradigm
Legal, Ethical, Environmental, Economic and Social Implications
Подольская Федерация Футбола в 2014 году
CV of Kazi Monjurul Alam
Ad

Similar to Linked Lists (20)

PPT
Lecture 2b lists
PPTX
Data structure day1
PPTX
Data Structures and Algorithms - Lec 05.pptx
PPTX
Linked lists linked lists vs Arrays.pptx
PPTX
Linked List.pptx
PPTX
Link list
PPTX
Link list
PPTX
LINKED LIST.pptx
PPTX
Data Structures-UNIT Four_Linked_List.pptx
PPTX
Linked Lists in Data Structures ppt .pptx
PPTX
Linked list
PPTX
Linked-Lists-A-Fundamental-Data-Structure.pptx
PPTX
mbit_Unit-2_Linked List.pptx
PPTX
Linked list
DOCX
Linked list.docx
PPT
Data Structures 3
PPTX
linked list in Data Structure, Simple and Easy Tutorial
PPTX
236170316121.pptx hii iam ms. aknown here is nothing important
PPTX
Linked list
PPTX
Linked list in Data Structure and Algorithm
Lecture 2b lists
Data structure day1
Data Structures and Algorithms - Lec 05.pptx
Linked lists linked lists vs Arrays.pptx
Linked List.pptx
Link list
Link list
LINKED LIST.pptx
Data Structures-UNIT Four_Linked_List.pptx
Linked Lists in Data Structures ppt .pptx
Linked list
Linked-Lists-A-Fundamental-Data-Structure.pptx
mbit_Unit-2_Linked List.pptx
Linked list
Linked list.docx
Data Structures 3
linked list in Data Structure, Simple and Easy Tutorial
236170316121.pptx hii iam ms. aknown here is nothing important
Linked list
Linked list in Data Structure and Algorithm

More from SabahtHussein (20)

PPTX
S3 HTML Hyperlinks and Images
PPTX
S3 HTML Lists and Tables
PPTX
S3 HTML Structure and Formatting
PPTX
S3 HTML Introduction
PPTX
S1 Programming Lesson 1
PPTX
S1 Web Development
PPTX
Video Games Development
PPTX
S2 Data Types
PPTX
Introduction to Pseudocode
PPTX
PPTX
Query Design
PPTX
PPTX
Query design
PPTX
S3 Field Types
PPTX
Testing a Database
PPTX
Testing a Database
PPTX
Database Testing and Evaluation
PPTX
DPA and GDPR
PPTX
Database Analysis
PPTX
Database Analysis
S3 HTML Hyperlinks and Images
S3 HTML Lists and Tables
S3 HTML Structure and Formatting
S3 HTML Introduction
S1 Programming Lesson 1
S1 Web Development
Video Games Development
S2 Data Types
Introduction to Pseudocode
Query Design
Query design
S3 Field Types
Testing a Database
Testing a Database
Database Testing and Evaluation
DPA and GDPR
Database Analysis
Database Analysis

Recently uploaded (20)

PDF
O7-L3 Supply Chain Operations - ICLT Program
PDF
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
PPTX
Orientation - ARALprogram of Deped to the Parents.pptx
PDF
VCE English Exam - Section C Student Revision Booklet
PPTX
Tissue processing ( HISTOPATHOLOGICAL TECHNIQUE
PDF
The Lost Whites of Pakistan by Jahanzaib Mughal.pdf
PDF
Computing-Curriculum for Schools in Ghana
PPTX
Lesson notes of climatology university.
PDF
A systematic review of self-coping strategies used by university students to ...
PPTX
Cell Types and Its function , kingdom of life
PDF
3rd Neelam Sanjeevareddy Memorial Lecture.pdf
PDF
Black Hat USA 2025 - Micro ICS Summit - ICS/OT Threat Landscape
PDF
Complications of Minimal Access Surgery at WLH
PDF
STATICS OF THE RIGID BODIES Hibbelers.pdf
PDF
Yogi Goddess Pres Conference Studio Updates
PPTX
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
PDF
RTP_AR_KS1_Tutor's Guide_English [FOR REPRODUCTION].pdf
PDF
Abdominal Access Techniques with Prof. Dr. R K Mishra
PDF
Anesthesia in Laparoscopic Surgery in India
PDF
O5-L3 Freight Transport Ops (International) V1.pdf
O7-L3 Supply Chain Operations - ICLT Program
Chapter 2 Heredity, Prenatal Development, and Birth.pdf
Orientation - ARALprogram of Deped to the Parents.pptx
VCE English Exam - Section C Student Revision Booklet
Tissue processing ( HISTOPATHOLOGICAL TECHNIQUE
The Lost Whites of Pakistan by Jahanzaib Mughal.pdf
Computing-Curriculum for Schools in Ghana
Lesson notes of climatology university.
A systematic review of self-coping strategies used by university students to ...
Cell Types and Its function , kingdom of life
3rd Neelam Sanjeevareddy Memorial Lecture.pdf
Black Hat USA 2025 - Micro ICS Summit - ICS/OT Threat Landscape
Complications of Minimal Access Surgery at WLH
STATICS OF THE RIGID BODIES Hibbelers.pdf
Yogi Goddess Pres Conference Studio Updates
school management -TNTEU- B.Ed., Semester II Unit 1.pptx
RTP_AR_KS1_Tutor's Guide_English [FOR REPRODUCTION].pdf
Abdominal Access Techniques with Prof. Dr. R K Mishra
Anesthesia in Laparoscopic Surgery in India
O5-L3 Freight Transport Ops (International) V1.pdf

Linked Lists

  • 1. Linked Lists DATA TYPES AND STRUCTURES
  • 2. Linked Lists  A linked list is a set of items which are arranged in an sequential order, like an array, but each item links to the next item in the list.  Linked lists have advantages and disadvantages:
  • 3. Advantages of Linked Lists  No fixed size: the list can expand or reduce when the program is run.  Linked lists are flexible: the order within the lists can be changed without having to move data (just the links are moved).  Memory efficient than an array: only needs to be the size required for the number of items stored, not as large as the possible number of items to be stored.
  • 4. Disadvantages of Linked Lists  Cannot use an index within a linked list to identify a particular item. To find a specific item you need to go through the list from beginning to end.
  • 5. Inserting and Adding Items  Inserting an item between two present items within a list can be achieved by changing the link of the pointer to point to the inserted item.  Adding an item to the end of the list can be done by redirecting the last link to the new item and linking the new item to NUL .  Adding an item to the beginning of the list can be done by redirecting the Head of the list to the new item and pointing its link to the formal first item.
  • 6. Deleting Items  Deleting an item from a list would be achieved by changing the link from the item before to the item after, bypassing the item which is no longer required.