Partial preview of the text
Download DSA unit 1 notes AKTU and more Slides Data Structures and Algorithms in PDF only on Docsity!
Introduction Dr. Kapil Kumar Sir ow Data Structure AKTU Syllabus UNIT- I a ““Tntroduction: Basic Terminology, Elementary Data Organization, Built in Data Types in C. Algoritam, Efficiency of an Algorithm, Time ef ALGO Complexity, Asymptotic s ractatiuin: Big Oh, Big Theta and Big Omega, Time Space at Ag (ae Data Types (ADT) Arrays Definition, Single and Multidimensional ral arta {Representation of Arrays: Row Major Order, and Column Major Order, Berivalion of ide si forbie for 1- ket 2-D,3- S Parte D and n-D Array Application of arrays, Sparse Matrifeetind ar Retr 2S parte tations. Matwics ADT | Linked lists: Jarray Implementation and Pointer Implementation of Singly Linked Lists, Doubly Linked List, Circularly Linked List, Operations on a Linked List. Insertion, Deletion, Traversal, | Polynomial ) Representation and Addition Subtraction & Multiplications of Single variable & Two variables Polynomial. éw «Basic Terminologies ow Type of Data - > Text Data (characters or alphabets) (1, 4 ,C Aft. = = > Number Data (0 to 9) —— » Alphanumeric Data (combination of numbers and characters) > Image Data (JPEG (Joint Photographic Experts Group), PNG (Portable Network Graphics)) —_ > Audio Video Data (MP3, MP4) Structures! Aue Binary (Q1) > UN Sfructures beg (o ~#) 9 “mal lo ‘ S ewe ~~ Date Semag — yy Oni Lm Deca ee ow .u.Basic Terminologies ow > Processing Element (PE) :- CPU Atv ge > instructions Control Word > i Len >» A computer instruction is an order given to a computer processor by a computer program. At the lowest level, each instruction is a sequence of Os and is that describes a physical operation the computer is to perform. Program:- Organized collection of instructions. — | Row lg tin CPU m fo ow ec .+..Basic Terminologies oe > The term "fields" refers to columns, or vertical categories of data while the term "records" refers to 1 > ne ae 6 i eee (different ) (Struct) > Arecord is defined as a finite, ordered collection of possibly heterogeneous elements of given entity. Entity:- An entity is called as set of certain attributes or properties with values. Key:- Each record in a file may contain many of field items, but in each record there exits field that —— uniquely determines the record in the file. » The uniquely field of a record is called as key field. > The key of record may be either an elementary item or a group item. Rol| a No Nic hd i: so a Selection Criteria for Data Structure The selection of a particular data structure stresses on the following 2 things: 1. The data structures must be rich pough in str re to reflect the relationship between the data. eo 2. The structure should be simple so that we can process data effectively whenever required. AS Sut Dale he Dif eres Severn Lee and Non Linear Data Structure Linear 1. Data elements are arranged in a linear order where each and every element is attached to its previous and next adjacent. Non Linear 1. Data elements are arranged in_ hierarchical ——— —— manner. ———Ss 2. Single level is involved. +— 2. Multiple levels are involved. 3. Easy to implement. + 3. Implementation is slightly complex. _—_— . 4. Data elements can neers a single run. 4. Data elements can not be traversed in as single SS run. + 5. Examples are arrays, linked list, stack, queue., 5. Examples are tree and graph. 3. According to Type of data stored in Data Structures:- a Data Structure fore Stung ——CO3O3O > In homogenous data structure, the data elements are of same type. e.g. Array. > In heterogeneous data structure, the data elements will be of different types. e.g. Structure. AKTU PYQs Q1. Define data, information, algorithm and data structure. Give the difference between linear —_—X—X—X—_, and non linear data structures with examples. AKTU: 2014-15 —_—_—_————————— eee Q2. Differentiate linear and non — linear data structures. AKTU: 2016-17 See Q3. Define the term Data Structure. List some linear and non linear data structures stating the SS meee ——_ ee" _—_—_—_— application are where they will be used. eS —_—._—«- int a: /x var. Bec */ 7 a [x ee ass Yralior