Chapter03

command
v0.0.0-...-2ded4ce Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 26, 2023 License: MIT Imports: 4 Imported by: 0

README

Chapter 3

Linear Data Structures
  • Lists
  • Sets
  • Tuples
  • Stacks
LinkedList
LinkedList is a sequence of nodes that have properties and a reference to the next node in
the sequence. It is a linear data structure that is used to store data. The data structure
permits the addition and deletion of components from any node next to another node. They
are not stored contiguously in memory, which makes them different arrays.
type Node struct{
    property int
    nextNode *Node
    }

The LinkedList class has headNode pointer as its property.

// LinkedList class
type LinkedList struct {
 headNode *Node
}

See LinkedList Source Code

Doubly Linked List
// Node class
type Node struct {
 property int
 nextNode *Node
 previousNode *Node
}
Sets
Tuples
Queue
Stacks

Documentation

Overview

main package has examples shown in Hands-On Data Structures and algorithms with Go book

main package has examples shown in Hands-On Data Structures and algorithms with Go book

main package has examples shown in Hands-On Data Structures and algorithms with Go book

main package has examples shown in Hands-On Data Structures and algorithms with Go book

main package has examples shown in Hands-On Data Structures and algorithms with Go book

main package has examples shown in Hands-On Data Structures and algorithms with Go book

main package has examples shown in Hands-On Data Structures and algorithms with Go book

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL