Lecture 1.pptxffffffffffffffcfffffffffff

andrewandjames 14 views 21 slides Mar 04, 2025
Slide 1
Slide 1 of 21
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21

About This Presentation

Ghghg


Slide Content

Data Structure Dr. Tauheed Ahmed Lecture 1: Introduction

2 C ontent s General information Course content Introduction to Data Structure Course weightage

R egarding Course Course Assignment and Lab Submissions: Mahindra Euclid Keeping the class strength in mind, you are encouraged to contact via email as it may not be feasible to meet in person most of the time. It is mandatory to attend all the exams and submit the assignments on time. In a supplementary no grade better than grade “D” can be obtained.

C ourse Content 4 Searching- Linear Search, Binary Search Sorting-Bubble, Insertion Sort, Selection Sort, Radix Sort, Quick sort, Heap Sort, Comparison of Sorting methods. Basic concepts - Algorithm Specification - Introduction, Recursive algorithms, Data Abstraction Performance analysis - time complexity and space complexity, Asymptotic Notation - Big O, Omega and Theta notations, Hashing. Singly Linked Lists-Operations-Insertion, Deletion, Concatenating singly linked lists, Circularly linked lists- Operations for Circularly linked lists, Doubly Linked Lists- Operations- Insertion, Deletion. Representation of single, two dimensional arrays, sparse matrices-array and linked representations. Stack ADT, definition, operations, array and linked implementations in C, applications-infix to postfix conversion, Postfix expression evaluation, recursion implementation, Queue ADT, definition and operations, array and linked Implementations in C, Circular Queues-Insertion and deletion operations, Deque (Double ended queue) ADT, array and linked implementations in C

C ourse Content 5 Trees – Terminology, Representation of Trees, Binary tree ADT, Properties of Binary Trees, Binary Tree Representations-array and linked representations, Binary Tree traversals, Max Priority Queue ADT-implementation-Max Heap-Definition, Insertion into a Max Heap, Deletion from a Max Heap., Binary Search Trees, Definition, Operations- Searching, Insertion and Deletion, AVL Tree. Graphs – Introduction, Definition, Terminology, Graph ADT, Graph Representations- Adjacency matrix, Adjacency lists, Graph traversals- DFS and BFS, Minimum Spanning Tree. 

T ext Books 6 Text Books: Fundamentals of Data structures in C, 2nd Edition, E.Horowitz , S.Sahni and Susan Anderson-Freed, Universities Press. Data structures A Programming Approach with C, D.S.Kushwaha and A.K.Misra , PHI. Data Structures, Seymour Lipschutz , 16 th Edition ,Schaum’s outlines Reference Books: Data structures: A Pseudocode Approach with C, 2nd edition, R.F.Gilberg And B.A.Forouzan , Cengage Learning. Data structures and Algorithm Analysis in C, 2nd edition, M.A.Weiss , Pearson. Data Structures using C, A.M.Tanenbaum,Y . Langsam , M.J.Augenstein , Pearson. Data structures and Program Design in C, 2nd edition, R.Kruse , C.L.Tondo and B.Leung,Pearson .

C ourse Weightage Evaluation Parameter Weightage Minor I 20% Minor II 20% End Sem 40% Lab 20%

W hy Study Data Structures?

W hat is a Data Structure? A data Structure is “the organization of data in a way so that it can be used efficiently”. A way of organizing, managing, and storing data for efficient access and modification. Performance Efficiency ? Memory

What is an Algorithm ? An algorithm is “A finite set of precise instructions for performing a computation or for solving a problem”.

I ntroduction Algorithm is a set of instruction written to carry out certain tasks & the data structure is the way of organizing the data with their logical relationship retained. To develop a program of an algorithm, we should select an appropriate data structure for that algorithm. Therefore, algorithm and its associated data structures from a program. What is a Program ? A Set of Instructions Data Structures + Algorithms Data Structure = A Container stores Data Algorithm = Logic + Control.

Classification of Data Structure

P rimitive Data Structure Primitive data structures are the basic building blocks of data manipulation and storage. They are predefined by programming languages and are used to represent single values

Classification of Data Structure

Non -Primitive Data Structure These are derived from the primitive data structures. The non-primitive data structures emphasize on structuring of a group of homogeneous (same type) or heterogeneous (different type) data items. The choice of a particular data structure depends on following two considerations It must be rich enough in structure to mirror the actual relationships of the real world data. The structure should be simple enough that one can effectively process the data when necessary.

Non -Primitive Data Structure: Operations Create Select or Access Update Search Sort Merge Destroy or Delete

Question 1. Which of the following best describes a data structure? A way of solving problems logically A method of organizing, managing, and storing data efficiently A set of instructions for performing a computation A program that processes data 2. What is the key feature of non-primitive data structures? They are predefined by programming languages. They emphasize structuring groups of data. They represent single values only. They require no memory allocation B B

A rrays An array is defined as a set of finite number of homogeneous elements or same data items. The simplest type of data structure is the linear array. Definition Note : Regardless of the notation, the number in is called as subscript and A[K] is called as subscripted variable   An array can contain one type of data only, either all integer, all float-point number or all character. If we choose the name for the array, then the elements of are denoted by Subscript notation : Parenthesis notation: Bracket notation:  

A rrays Declaration of array is as follows: int arr [10] Declaration Where, int specifies the data type or type of elements arrays stores. “ arr ” is the name of array & the number specified inside the square brackets is the number of elements an array can store, this is also called sized or length of array.

A rrays Following are some of the concepts to be remembered about arrays:

Arrays: Example A linear array STUDENT consisting of the names of six student is pictured as: Ex. 1.1 A chain of 28 stores, each having 4 department may list its weekly sales as: Ex. 1.2 John Sandra Tom Kelly Reed Smith Store/ Dept 1 2 3 4 1 31 342 2342 234 2 213 1234 2134 321 3 234 123 4654 4567 … … … … … 28 234 243 4567 342
Tags