Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
Upcoming SlideShare
Loading in …5
×

# Basic terminologies

1,625 views

Published on

Basic terminologies for

Published in: Education
• Full Name
Comment goes here.

Are you sure you want to Yes No
Your message goes here
• Be the first to comment

### Basic terminologies

1. 1. DataStructures Basic Terminologies 1
2. 2. DataStructures “Clever” waysto organizeinformation in order to enable efficient computation – What do wemean by clever? – What do wemean by efficient? 2 Basic Terminologies & Asymptotic Notations
3. 3. Definition • DataStructureisaway of collecting and organizing data in such away that wecan perform operationson these datain an effectiveway. DataStructuresisabout rendering dataelementsin termsof somerelationship, for better organization and storage. • Datastructurescan implement oneor moreparticular  abstract datatypes(ADT), which arethemeansof specifying thecontract of operationsand their complexity . Data Structures - Introduction 3
4. 4. Picking thebest DataStructurefor thejob • Thedatastructureyou pick needsto suppo rt the operationsyou need • Ideally it supportstheoperationsyou will usemost often in an efficient manner • Examplesof operations: – A List with operationsinsert and delete – A Stack with operationspushand pop 4 Basic Terminologies & Asymptotic Notations
5. 5. Terminology • Abstract DataType(ADT) – Mathematical description of an object with set of operationson theobject. Useful building block. • Algorithm – A high level, languageindependent, description of astep-by-step process • Datastructure – A specific family of algorithmsfor implementing an abstract datatype. • Implementation of datastructure – A specific implementation in aspecific language 5 Basic Terminologies & Asymptotic Notations
6. 6. Terminology • Data Datarefersto valueor set of values. e.g.Marksobtained by thestudents. • Datatype datatypeisaclassification identifying oneof varioustypes of data, such as floating-point, integer, or Boolean, that determinesthepossiblevaluesfor that type; theoperations that can bedoneon valuesof that type; and theway values of that typecan bestored Data Structures - Introduction 6
7. 7. Terminology • Primitivedatatype: Thesearebasic datatypesthat areprovided by the programming languagewith built-in support. Thesedata typesare nativeto thelanguage. Thisdatatypeis supported by machinedirectly • Variable Variableisasymbolic namegiven to someknown or unknown quantity or information, for thepurposeof allowing thenameto beused independently of the information it represents. Data Structures - Introduction 7
8. 8. Terminology • Record Collection of related dataitemsisknown asrecord. The elementsof recordsareusually Called fieldsor members. Recordsare distinguished from arraysby thefact that their number of fieldsistypically fixed, each field hasa name, and that each field may haveadifferent type. • Program A sequenceof instructionsthat acomputer can interpret and execute. Data Structures - Introduction 8
9. 9. Terminology examples • A stack isan abstract data type supporting push, pop and isEmpty operations • A stack data structure could usean array, alinked list, or anything that can hold data • Onestack implementatio n isjava.util.Stack; another is java.util.LinkedList 9 Basic Terminologies & Asymptotic Notations
10. 10. Concepts vs. Mechanisms • Abstract • Pseudocode • Algorithm – A sequenceof high-level, languageindependent operations, which may act upon an abstracted view of data. • Abstract DataType(ADT) – A mathematical description of an object and theset of operations on theobject. • Concrete • Specific programming language • Program – A sequenceof operationsin a specific programming language, which may act upon real datain theform of numbers, images, sound, etc. • Datastructure – A specific way in which a program’sdataisrepresented, which reflectsthe programmer’sdesign choices/goals. 10
11. 11. Why So Many DataStructures? Ideal datastructure: “fast”, “elegant”, memory efficient Generatestensions: – timevs. space – performancevs. elegance – generality vs. simplicity – oneoperation’sperformancevs. another’s The study o f data structures is the study o f tradeo ffs. That’ s why we have so many o f them! 11Basic Terminologies & Asymptotic Notations