Data Structures Notes
Data Structures Notes
Dr. R. Gowri
Assistant Professor
Department of Computer Applications
Sona College of Arts and Science
Salem
Data Structure
Data Structure is a way to store and organize data
data is represented
Ques:
What is Data Structure?
Why Data Struture?
Uses of Data Structure
Ques:
What is the necessity of Data Structure?
How Data Struture helps in solving a problem?
Algorithms
Algorithm is a finite set of well-defined procedure for solving a problem
Problem Solving
Problem solving is a logical process of breaking down the problem into
smaller parts, each of which can be solved step by step to obtain the final
solution.
Ques:
What is an algorithm?
What is the use of algorithm?
Algorithm Properties
It must be correct.
It must be composed of a series of concrete steps.
There can be no ambiguity as to which step will be performed next.
It must be composed of a finite number of steps.
It must terminate.
It should be efficient and flexible
It should use less memory space as much as possible
Number of inputs: zero or more
Number of outputs: one or more
Computer Program
problem
◦ A data structure defines a way of organizing all data items that consider not
only the elements stored but also stores the relationship between the
elements
Ques:
What do you mean by a program?
How a program is designed?
Applications of Data Structure
Artificial intelligence
Compiler design
Machine learning
Database design and management
Blockchain
Numerical and Statistical analysis
Operating system development
Image & Speech Processing
Cryptography
Ques:
List some applications of Data Structure?
What is the Scope of Data Struture?
Data Structure Classification
Ques:
How Data Structure classified?
What are the types of Data Struture?
List some data structures.
Primitive Data Structure
The basic data structures that directly operate upon
the machine instructions
Ques:
What is Primitive Data
Structure?
Non-Primitive Data Structure
Non-primitive data structure is a type of data
structure that can store the data of more than one
type.
Ques:
What is Non-primitive Data Structure?
Why it is called as non-primitive Data Struture?
What are the types of non-primitive data structure?
Linear vs Non-linear Data Structure
Operations of Linear Data Structure
Ques:
What are the operations of Linear Data
Structure?
Array Data Structure
Properties of Array
Array Types
Example
Linked List
Linked List Types
Array Vs Linked List
Array Vs Linked List
Stack
Stack Implementation
Applications of Stack
Queue
Queue Operations
Applications of Queue
Queue types
Tree Data Structure
Tree Data Structure
Properties of Tree
Binary Tree Traversal
Binary Tree Traversal
Binary Tree Traversal
Graph
A graph is defined as G = (V, E), where V is the set of vertices
(nodes) and E is the set of edges (arcs) connecting the vertices.
An edge is represented as a pair (u, v).
Types of Graphs
1. Directed graph
2. Undirected graph
Undirected Graph
In an undirected graph, the pair of vertices representing any
edge is unordered.
Thus, the pairs (v1, v2) and (v2, v1) represents the same edge.
Graph Terminologies