SlideShare une entreprise Scribd logo
1  sur  4
Title: Programs based on linked list.

Introduction:

 The linked allocation method of storage is more suitable for much computer application. It can
result in both the efficient use of computer storage and computer time. It has following
characteristics:

   1. Unpredictable storage requirement
   2. Extensive manipulation of data stored

   Linked List: A linked list or one way list or chain list is a linear collection of data elements
   called node where the linear order is given by means of pointer. Each node is divided into
   two parts:

   1. Information of the elements.
   2. Address of the next node in the list called as linked field or next pointer field. The
      pointer of the last node contains a special value called null pointer which is an invalid
      address. In actual practice, 0 or negative number is used for null pointer.

       Important concepts related to Linked List:

       Node: Each item in the list is called a node and contains two fields such as:
              1. Information field
              2. Next address field

       1. Information field: The Information field holds the actual elements on the list.

       2. Next address field: The Next address field contains the address of the next node in
       the list.

       Pointer and Null pointer: The address which is used to access a particular node is known
       as a pointer. The entire linked list is accessed from an external pointer list that points to
       the first node in the list. The next address of the last node in the list contains a special
       value, known as null, which is not valid address. This null pointer is used to signal the
       end of the list.

       Empty list: The list with no nodes on it is called empty list or null list. The value of the
       external pointer list to such a list is the null pointer. A list can be initialize to the empty
       list by the operation list=null.
Operations on linked list:

       1. Searching
       2. Insertion
       3. Deletion

       1. Searching for node from linked list
          Algorithm: Search_node(Start, Data)
          [Searches for data, start ptr to first node]
          Step 1: Start
          Step 2: Accept linked list and data
          Step 3: Set temp=Start
          Step 4: While link [temp] not equal to Null [check till end]
                   If info [temp] =Data, then
                 Write: “Found Successfully”
                    Exit [if found, stop]
                 [End of if]
                  Set Temp=Link [tamp] [pointer is incremented to next]
                  [End of while]
          Step 5: Write: “Not Found”
          Step 6: Exit [stop]




Types of linked list:

1. Linear

2. Doubly

3. Circular

1. Linear linked list

 Contained within itself the address of the next items such an explicit ordering gives rise to a data
structure, which is known as a linear linked list.
info          Next             Node




2. Doubly linked list

In a doubly linked list, each node contains, besides the next-node link, a second link field
pointing to the previous node in the sequence. The two links may be called forward(s) and
backwards, or next and previous.

   Head                           address to next node             last




                        Address to previous node

3. Circular

Circular list

In a circularly linked list, all nodes are linked in a continuous circle, without using null. For lists
with a front and a back (such as a queue), one stores a reference to the last node in the list. The
next node after the last node is the first node. Elements can be added to the back of the list and
removed from the front in constant time.

Circularly linked lists can be either singly or doubly linked.

Both types of circularly linked lists benefit from the ability to traverse the full list beginning at
any given node. This often allows us to avoid storing firstNode and lastNode, although if the list
may be empty we need a special representation for the empty list, such as a lastNode variable
which points to some node in the list or is null if it's empty; we use such a lastNode here. This
representation significantly simplifies adding and removing nodes with a non-empty list, but
empty lists are then a special case.



                First node                                  last node
Advantages of linked list :

1. Linked list is an example of dynamic data structure

2. Linked list can be grow and shrink during execution of the program

3. It allows to use memory efficiently the memory is not allocated in advance so according to
need,memory can be allocated

4. Representation of the linear data structure can be easily implement using it.

5. Memory is freed whenever there is no need of it.

6. Insertion and deletion are efficient and easy.

Contenu connexe

Tendances (20)

Lecture 2b lists
Lecture 2b listsLecture 2b lists
Lecture 2b lists
 
Introduction to linked lists
Introduction to linked listsIntroduction to linked lists
Introduction to linked lists
 
Link list
Link listLink list
Link list
 
Presentation on circular linked list
Presentation on circular linked listPresentation on circular linked list
Presentation on circular linked list
 
Circular linked list
Circular linked listCircular linked list
Circular linked list
 
Linked List
Linked ListLinked List
Linked List
 
Link list 2
Link list 2Link list 2
Link list 2
 
computer notes - Data Structures - 33
computer notes - Data Structures - 33computer notes - Data Structures - 33
computer notes - Data Structures - 33
 
Deep Copy of a Linked List
Deep Copy of a Linked ListDeep Copy of a Linked List
Deep Copy of a Linked List
 
Unix training session 2
Unix training   session 2Unix training   session 2
Unix training session 2
 
List data structure
List data structure List data structure
List data structure
 
Application of Data structure
Application of Data structureApplication of Data structure
Application of Data structure
 
Unit 3 dsa LINKED LIST
Unit 3 dsa LINKED LISTUnit 3 dsa LINKED LIST
Unit 3 dsa LINKED LIST
 
Linked list
Linked listLinked list
Linked list
 
poornima.coseq
poornima.coseqpoornima.coseq
poornima.coseq
 
Bca ii dfs u-2 linklist,stack,queue
Bca ii  dfs u-2 linklist,stack,queueBca ii  dfs u-2 linklist,stack,queue
Bca ii dfs u-2 linklist,stack,queue
 
Arrays
ArraysArrays
Arrays
 
Singly Linked List
Singly Linked ListSingly Linked List
Singly Linked List
 
DATA STRUCTURES - SHORT NOTES
DATA STRUCTURES - SHORT NOTESDATA STRUCTURES - SHORT NOTES
DATA STRUCTURES - SHORT NOTES
 
Data Structure lec#2
Data Structure lec#2Data Structure lec#2
Data Structure lec#2
 

En vedette

Network Data Representation
Network Data RepresentationNetwork Data Representation
Network Data RepresentationPOOJA MEHTA
 
TPC CONCEPT Performare echipe manageriale
TPC CONCEPT Performare echipe managerialeTPC CONCEPT Performare echipe manageriale
TPC CONCEPT Performare echipe managerialeTPC CONCEPT
 
GWC13 - Daniel González de la Vega - Increasing engagement at math teaching
GWC13 - Daniel González de la Vega - Increasing engagement at math teachingGWC13 - Daniel González de la Vega - Increasing engagement at math teaching
GWC13 - Daniel González de la Vega - Increasing engagement at math teachinggamificationworldcongress
 
BACTERIAL INFECTION AND IMMUNE SYSTEM RESPONSE
BACTERIAL INFECTION AND IMMUNE SYSTEM RESPONSEBACTERIAL INFECTION AND IMMUNE SYSTEM RESPONSE
BACTERIAL INFECTION AND IMMUNE SYSTEM RESPONSEDiana Agudelo
 
Ardi jurnal ic
Ardi jurnal icArdi jurnal ic
Ardi jurnal icArdi Novra
 
CARVEX PS 420
CARVEX PS 420CARVEX PS 420
CARVEX PS 420liub_tts
 
GALNT11 as a new molecular marker in chronic lymphocytic leukemia
GALNT11 as a new molecular marker in chronic lymphocytic leukemiaGALNT11 as a new molecular marker in chronic lymphocytic leukemia
GALNT11 as a new molecular marker in chronic lymphocytic leukemiaDiana Agudelo
 
GWC2013 - Arturo Castelló - PlayJugo - Beating inertia and having fun at it
GWC2013 - Arturo Castelló - PlayJugo - Beating inertia and having fun at itGWC2013 - Arturo Castelló - PlayJugo - Beating inertia and having fun at it
GWC2013 - Arturo Castelló - PlayJugo - Beating inertia and having fun at itgamificationworldcongress
 
GWC2013 - Jaume Juan - Apesoft - Competing to Increase Sales
GWC2013 - Jaume Juan - Apesoft - Competing to Increase SalesGWC2013 - Jaume Juan - Apesoft - Competing to Increase Sales
GWC2013 - Jaume Juan - Apesoft - Competing to Increase Salesgamificationworldcongress
 
Kolaj menggunakan ict@paint
Kolaj menggunakan ict@paintKolaj menggunakan ict@paint
Kolaj menggunakan ict@paintWes Mirid
 
Sos besu forum_v4
Sos besu forum_v4Sos besu forum_v4
Sos besu forum_v4rajarshir
 
Presentasjon om biler
Presentasjon om bilerPresentasjon om biler
Presentasjon om bilerAbdelhay1961
 
GWC14: Carlos Guardiola - "Who gamifies the gamificators?
GWC14: Carlos Guardiola - "Who gamifies the gamificators?GWC14: Carlos Guardiola - "Who gamifies the gamificators?
GWC14: Carlos Guardiola - "Who gamifies the gamificators?gamificationworldcongress
 

En vedette (20)

Grunt
GruntGrunt
Grunt
 
Network Data Representation
Network Data RepresentationNetwork Data Representation
Network Data Representation
 
TPC CONCEPT Performare echipe manageriale
TPC CONCEPT Performare echipe managerialeTPC CONCEPT Performare echipe manageriale
TPC CONCEPT Performare echipe manageriale
 
GWC13 - Daniel González de la Vega - Increasing engagement at math teaching
GWC13 - Daniel González de la Vega - Increasing engagement at math teachingGWC13 - Daniel González de la Vega - Increasing engagement at math teaching
GWC13 - Daniel González de la Vega - Increasing engagement at math teaching
 
BACTERIAL INFECTION AND IMMUNE SYSTEM RESPONSE
BACTERIAL INFECTION AND IMMUNE SYSTEM RESPONSEBACTERIAL INFECTION AND IMMUNE SYSTEM RESPONSE
BACTERIAL INFECTION AND IMMUNE SYSTEM RESPONSE
 
Ardi jurnal ic
Ardi jurnal icArdi jurnal ic
Ardi jurnal ic
 
Seta de-che-aio-09-2012
Seta de-che-aio-09-2012Seta de-che-aio-09-2012
Seta de-che-aio-09-2012
 
CARVEX PS 420
CARVEX PS 420CARVEX PS 420
CARVEX PS 420
 
MUN U.K.
MUN U.K.MUN U.K.
MUN U.K.
 
GALNT11 as a new molecular marker in chronic lymphocytic leukemia
GALNT11 as a new molecular marker in chronic lymphocytic leukemiaGALNT11 as a new molecular marker in chronic lymphocytic leukemia
GALNT11 as a new molecular marker in chronic lymphocytic leukemia
 
GWC2013 - Arturo Castelló - PlayJugo - Beating inertia and having fun at it
GWC2013 - Arturo Castelló - PlayJugo - Beating inertia and having fun at itGWC2013 - Arturo Castelló - PlayJugo - Beating inertia and having fun at it
GWC2013 - Arturo Castelló - PlayJugo - Beating inertia and having fun at it
 
GWC2013 - Jaume Juan - Apesoft - Competing to Increase Sales
GWC2013 - Jaume Juan - Apesoft - Competing to Increase SalesGWC2013 - Jaume Juan - Apesoft - Competing to Increase Sales
GWC2013 - Jaume Juan - Apesoft - Competing to Increase Sales
 
Kolaj menggunakan ict@paint
Kolaj menggunakan ict@paintKolaj menggunakan ict@paint
Kolaj menggunakan ict@paint
 
Water bobble
Water bobbleWater bobble
Water bobble
 
Sos besu forum_v4
Sos besu forum_v4Sos besu forum_v4
Sos besu forum_v4
 
Presentasjon om biler
Presentasjon om bilerPresentasjon om biler
Presentasjon om biler
 
Tugas agama
Tugas agamaTugas agama
Tugas agama
 
Katharina reiss
Katharina reissKatharina reiss
Katharina reiss
 
江戸川花火大会
江戸川花火大会江戸川花火大会
江戸川花火大会
 
GWC14: Carlos Guardiola - "Who gamifies the gamificators?
GWC14: Carlos Guardiola - "Who gamifies the gamificators?GWC14: Carlos Guardiola - "Who gamifies the gamificators?
GWC14: Carlos Guardiola - "Who gamifies the gamificators?
 

Similaire à Link list assi

Different types of Linked list.
Different types of Linked list.Different types of Linked list.
Different types of Linked list.JAYANTAOJHA
 
1.3 Linked List.pptx
1.3 Linked List.pptx1.3 Linked List.pptx
1.3 Linked List.pptxssuserd2f031
 
Linked list in Data Structure and Algorithm
Linked list in Data Structure and Algorithm Linked list in Data Structure and Algorithm
Linked list in Data Structure and Algorithm KristinaBorooah
 
Linked List Presentation in data structurepptx
Linked List Presentation in data structurepptxLinked List Presentation in data structurepptx
Linked List Presentation in data structurepptxnikhilcse1
 
Operations on linked list
Operations on linked listOperations on linked list
Operations on linked listSumathi Kv
 
DSA chapter 4.pptxhdjaaaaaadjhsssssssssssssssssssssssssss
DSA chapter 4.pptxhdjaaaaaadjhsssssssssssssssssssssssssssDSA chapter 4.pptxhdjaaaaaadjhsssssssssssssssssssssssssss
DSA chapter 4.pptxhdjaaaaaadjhsssssssssssssssssssssssssssbeshahashenafe20
 
In this lab we will write code for working with a Linked List. Node .pdf
In this lab we will write code for working with a Linked List.  Node .pdfIn this lab we will write code for working with a Linked List.  Node .pdf
In this lab we will write code for working with a Linked List. Node .pdffms12345
 
Linked list (introduction) 1
Linked list (introduction) 1Linked list (introduction) 1
Linked list (introduction) 1DrSudeshna
 
Linked list and its operations - Traversal
Linked list and its operations - TraversalLinked list and its operations - Traversal
Linked list and its operations - Traversalkasthurimukila
 
ds-lecture-4-171012041008 (1).pdf
ds-lecture-4-171012041008 (1).pdfds-lecture-4-171012041008 (1).pdf
ds-lecture-4-171012041008 (1).pdfKamranAli649587
 
Deletion from single way linked list and search
Deletion from single way linked list and searchDeletion from single way linked list and search
Deletion from single way linked list and searchEstiak Khan
 
linked list in data structure
linked list in data structure linked list in data structure
linked list in data structure shameen khan
 
Linked List in Data Structure
Linked List in Data StructureLinked List in Data Structure
Linked List in Data StructureMeghaj Mallick
 
data structures lists operation of lists
data structures lists operation of listsdata structures lists operation of lists
data structures lists operation of listsmuskans14
 

Similaire à Link list assi (20)

Linked list.docx
Linked list.docxLinked list.docx
Linked list.docx
 
Different types of Linked list.
Different types of Linked list.Different types of Linked list.
Different types of Linked list.
 
1.3 Linked List.pptx
1.3 Linked List.pptx1.3 Linked List.pptx
1.3 Linked List.pptx
 
Linked list in Data Structure and Algorithm
Linked list in Data Structure and Algorithm Linked list in Data Structure and Algorithm
Linked list in Data Structure and Algorithm
 
Linked List Presentation in data structurepptx
Linked List Presentation in data structurepptxLinked List Presentation in data structurepptx
Linked List Presentation in data structurepptx
 
Operations on linked list
Operations on linked listOperations on linked list
Operations on linked list
 
single linked list
single linked listsingle linked list
single linked list
 
Algo>ADT list & linked list
Algo>ADT list & linked listAlgo>ADT list & linked list
Algo>ADT list & linked list
 
DSA chapter 4.pptxhdjaaaaaadjhsssssssssssssssssssssssssss
DSA chapter 4.pptxhdjaaaaaadjhsssssssssssssssssssssssssssDSA chapter 4.pptxhdjaaaaaadjhsssssssssssssssssssssssssss
DSA chapter 4.pptxhdjaaaaaadjhsssssssssssssssssssssssssss
 
Linked list
Linked listLinked list
Linked list
 
In this lab we will write code for working with a Linked List. Node .pdf
In this lab we will write code for working with a Linked List.  Node .pdfIn this lab we will write code for working with a Linked List.  Node .pdf
In this lab we will write code for working with a Linked List. Node .pdf
 
Linked list (introduction) 1
Linked list (introduction) 1Linked list (introduction) 1
Linked list (introduction) 1
 
Linked list and its operations - Traversal
Linked list and its operations - TraversalLinked list and its operations - Traversal
Linked list and its operations - Traversal
 
ds-lecture-4-171012041008 (1).pdf
ds-lecture-4-171012041008 (1).pdfds-lecture-4-171012041008 (1).pdf
ds-lecture-4-171012041008 (1).pdf
 
Linked list (1).pptx
Linked list (1).pptxLinked list (1).pptx
Linked list (1).pptx
 
Deletion from single way linked list and search
Deletion from single way linked list and searchDeletion from single way linked list and search
Deletion from single way linked list and search
 
linked list in data structure
linked list in data structure linked list in data structure
linked list in data structure
 
Linked List in Data Structure
Linked List in Data StructureLinked List in Data Structure
Linked List in Data Structure
 
data structures lists operation of lists
data structures lists operation of listsdata structures lists operation of lists
data structures lists operation of lists
 
Link list
Link listLink list
Link list
 

Dernier

Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024SynarionITSolutions
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Principled Technologies
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsRoshan Dwivedi
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 

Dernier (20)

Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 

Link list assi

  • 1. Title: Programs based on linked list. Introduction: The linked allocation method of storage is more suitable for much computer application. It can result in both the efficient use of computer storage and computer time. It has following characteristics: 1. Unpredictable storage requirement 2. Extensive manipulation of data stored Linked List: A linked list or one way list or chain list is a linear collection of data elements called node where the linear order is given by means of pointer. Each node is divided into two parts: 1. Information of the elements. 2. Address of the next node in the list called as linked field or next pointer field. The pointer of the last node contains a special value called null pointer which is an invalid address. In actual practice, 0 or negative number is used for null pointer. Important concepts related to Linked List: Node: Each item in the list is called a node and contains two fields such as: 1. Information field 2. Next address field 1. Information field: The Information field holds the actual elements on the list. 2. Next address field: The Next address field contains the address of the next node in the list. Pointer and Null pointer: The address which is used to access a particular node is known as a pointer. The entire linked list is accessed from an external pointer list that points to the first node in the list. The next address of the last node in the list contains a special value, known as null, which is not valid address. This null pointer is used to signal the end of the list. Empty list: The list with no nodes on it is called empty list or null list. The value of the external pointer list to such a list is the null pointer. A list can be initialize to the empty list by the operation list=null.
  • 2. Operations on linked list: 1. Searching 2. Insertion 3. Deletion 1. Searching for node from linked list Algorithm: Search_node(Start, Data) [Searches for data, start ptr to first node] Step 1: Start Step 2: Accept linked list and data Step 3: Set temp=Start Step 4: While link [temp] not equal to Null [check till end] If info [temp] =Data, then Write: “Found Successfully” Exit [if found, stop] [End of if] Set Temp=Link [tamp] [pointer is incremented to next] [End of while] Step 5: Write: “Not Found” Step 6: Exit [stop] Types of linked list: 1. Linear 2. Doubly 3. Circular 1. Linear linked list Contained within itself the address of the next items such an explicit ordering gives rise to a data structure, which is known as a linear linked list.
  • 3. info Next Node 2. Doubly linked list In a doubly linked list, each node contains, besides the next-node link, a second link field pointing to the previous node in the sequence. The two links may be called forward(s) and backwards, or next and previous. Head address to next node last Address to previous node 3. Circular Circular list In a circularly linked list, all nodes are linked in a continuous circle, without using null. For lists with a front and a back (such as a queue), one stores a reference to the last node in the list. The next node after the last node is the first node. Elements can be added to the back of the list and removed from the front in constant time. Circularly linked lists can be either singly or doubly linked. Both types of circularly linked lists benefit from the ability to traverse the full list beginning at any given node. This often allows us to avoid storing firstNode and lastNode, although if the list may be empty we need a special representation for the empty list, such as a lastNode variable which points to some node in the list or is null if it's empty; we use such a lastNode here. This representation significantly simplifies adding and removing nodes with a non-empty list, but empty lists are then a special case. First node last node
  • 4. Advantages of linked list : 1. Linked list is an example of dynamic data structure 2. Linked list can be grow and shrink during execution of the program 3. It allows to use memory efficiently the memory is not allocated in advance so according to need,memory can be allocated 4. Representation of the linear data structure can be easily implement using it. 5. Memory is freed whenever there is no need of it. 6. Insertion and deletion are efficient and easy.