0% found this document useful (0 votes)
3 views

Data Structure

A data structure organizes and stores data to allow efficient access and modification. There are built-in data structures like arrays and structures, and abstract data types (ADTs) like linked lists, stacks, queues, trees, heaps, and hash tables. A linked list is a linear data structure where each element is a node containing data and a pointer to the next node, allowing efficient insertion and removal. Linked lists use slightly more memory than arrays but allow sequential access and require traversing to access elements. Stacks follow the last-in, first-out principle and only allow insertion/deletion at one end called the top.

Uploaded by

Nasir Kabir
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views

Data Structure

A data structure organizes and stores data to allow efficient access and modification. There are built-in data structures like arrays and structures, and abstract data types (ADTs) like linked lists, stacks, queues, trees, heaps, and hash tables. A linked list is a linear data structure where each element is a node containing data and a pointer to the next node, allowing efficient insertion and removal. Linked lists use slightly more memory than arrays but allow sequential access and require traversing to access elements. Stacks follow the last-in, first-out principle and only allow insertion/deletion at one end called the top.

Uploaded by

Nasir Kabir
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

DATA STRUCTURE

A data structure is a model where data is organised ,manage and stored in a format that enable
efficient access and modification of data. Different form of data may required Different types of data
structure.

DATA STRUCTURE
1. In-built

1. Arrays
2. Structure

2. ADT Abstract Data type

1. Linked list
2. Stacks
3. Queues
4. Trees
5. Heaps
6. Heaps graphs
7. Hash tables

Linked list

A inked list is linear data structure where each element is separate object known as a node.
Each node contains some data and points to the next node in the structure forming a
sequence. This structure allows for efficient insertions or removal of elements from any
position as only the link is needed to be modified to point some other elements or node

ADVANTAGES OVER AN ARRAY

1. It is not fixed in size.


2. Efficient insertion and deletion.

DISADVANTAGES OVER AN ARRAY

1. Slightly more memory usage.


2. Sequential access.
3. If you want to access an elements in the list you have to traverse

TYPES OF LINKED LIST

1. Singly
2. Doubly
3. Circular
USES OF LINKED LIST

1. Is used to implement other data structures such as Stacks, Queues and non linear data
structure such as trees and graphs1.
2. It has uses in harsh chaining for the implementation in open chaining.

Stack

A stack is a linear data structure which stores its elements in a particular order. The order
followed is known as LIFO (last in first out). Stack is an ordered list which insertion/deletion
can be performed at only one end which is the Top.

THREE OPERATIONS THAT WE PERFORMED ON STACK

1. Push
2. Pop
3. Peek

You might also like