COMP 2140 Lecture 5: 09_19_list.pdf

26 views23 pages

Document Summary

An abstract data type (adt) consists of a data structure: a collection of data its organization, structure, properties the operations that can be performed: what can be done to change, manipulate, or look at the data. Information hiding (for example, a java interface) provides a allows the adt to hide all implementation details. The proper way to implement an adt in java is using the interface mechanism (not required in this course) Not really abstract: basic structure in most languages. List is a fundamental and very useful adt, which is often used to implement other adts: Do not confuse an adt with its implementation. For example, we could use an array to implemented a list, but that does not mean the list is an array. Another method of implementing adt list (other than array) Allocate memory for another element when needed only. Linked list an item a reference to the next node in the list.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers