Friday, 25 August 2017

Abstract data type

Abstract Data Type (ADT) is a data type, where only behavior is defined but not implementation. Opposite of ADT is Concrete Data Type (CDT), where it contains an implementation of ADT.

An abstract data type is defined as a mathematical model of the data objects that make up a data type as well as the functions that operate on these objects. There are no standard conventions for defining them.

Array, List, Map, Queue, Set, Stack, Table, Tree, and Vector are ADTs. Each of these ADTs have many implementations i.e. CDT. The container is a high-level ADT of above all ADTs.

Real life example
Book is Abstract (Telephone Book is an implementation).

No comments:

Post a Comment

Related Posts Plugin for WordPress, Blogger...