Anna CS 3301 - DATA STRUCTURE

Unformatted text preview:

DATA STRUCTURE DEFINITION ADVANTAGES AND DISADVANTAGES Data Structures Organization and Efficiency Data Structure Selection Space Time and Reusability When selecting a data structure it is important to consider the following factors Space The amount of memory used by the data structure Time The time complexity of various operations on the data structure Reusability The ability to use the same data structure for different tasks Abstract Data Types ADTs ADTs or Abstract Data Types are blueprints for data structures They define the operations that can be performed on the data structure as well as any constraints on the data For example a stack is an ADT that defines the operations push pop and top and dictates that elements must be added and removed from the stack in a last in first out LIFO order When designing a data structure it is helpful to first define an ADT for it as this will help to ensure that the data structure meets the needs of the task at hand ADTs Abstract Data Types Blueprints for Data Structures Abstract Data Types ADTs are high level descriptions of data structures that define their behavior using a set of values and operations They provide an interface that specifies how data can be manipulated without revealing the details of the implementation Components of an ADT Space Time Values Data The data that an ADT operates on Data Structures Organization and Efficiency Data Structures Organize and store data efficiently Allow for efficient data manipulation Examples arrays linked lists trees graphs hash tables Data Structure Selection Space Time and Reusability Consider the amount of memory required by the data structure Some data structures are more space efficient than others Choose a data structure that strikes a balance between time efficiency and space efficiency Consider the time required for operations on the data structure Some data structures provide faster operations for certain tasks Choose a data structure that allows for efficient execution of required operations Reusability Consider using existing data structures and libraries Can save development time and reduce bugs Be aware of potential limitations or trade offs ADTs Blueprints for Data Structures Abstract Data Types ADTs Define an interface for data structures Specify a set of operations that can be performed on the data structure Abstracts away implementation details Benefits Allows for easier data structure design and implementation Promotes modular programming Encourages encapsulation and information hiding Notes When selecting a data structure consider both space and time efficiency Reusability can save development time and reduce bugs ADTs define an interface for data structures and allow for easier design and implementation with modular programming and information hiding


View Full Document

Anna CS 3301 - DATA STRUCTURE

Download DATA STRUCTURE
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view DATA STRUCTURE and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view DATA STRUCTURE 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?