Download presentation
Presentation is loading. Please wait.
Published byCarol Perkins Modified over 8 years ago
2
Data Structures
3
What The Course Is About Data structures is concerned with the representation and manipulation of data.
4
What The Course Is About Algorithm design methods needed to develop programs that do the data manipulation.
5
Data Structures and Algorithms s Data structures have operations that manipulate the data. s The design and implementation of these operations involve algorithms that consist of a finite sequence of instructions to perform a task. s Nicolas Wirth coined the expression "data structures + algorithms = programming."
6
Data Structures and Object-Oriented Programming s Modern object-oriented programming is an ideal mechanism for designing and implementing a data structure. s Java has good object-oriented design constructs that support a modern view of data structures.
7
Grades 平時 20% 期中考 40% 期末考 40%
8
Stack s A container of objects that are inserted and removed according to the last-in-first-out (LIFO) principle. s Only the last (the most recently inserted) object can be removed.
9
Queue s Differs from a stack in that its insertion and removal follows the first-in-first-out (FIFO) principle. s The element which has been in the queue the longest may be removed.
10
Sequence (or list) s A collection of linearly arranged element (a linear order). s Provides methods for accessing, inserting, and removing arbitrary elements. s Notion of position, before and after. s Stacks and queues are a restricted form of a sequence. s Example, –A,B,C,D,E,F –a_1, a_2, a_3, …
11
Tree s A collection of objects arranged in a hierarchical fashion. s E.g., organization of corporation, table of contents, dos/unix file systems, family tree.
12
Tree s Example,
13
Priority queue s An abstract type for storing a collection of prioritized elements that s supports arbitrary element insertion but support s removal of elements only in order of priority.
14
Dictionaries s The collection of objects organized for fast lookup using search keys. s Examples, –binary search trees. –AVL trees.
15
Graphs s Representing a way of connections or relationships between pairs of objects.
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.