You are on page 1of 2

ADTs (abstract data types),

according to Eck (2020), is a set


of possible values and a set of
operations on those values,
without any specification of how
the values are to be represented
or
how the operations are to be
implemented. An ADT specifies
1) what can be stored in the
ADT, 2)
what operations can be done.
ADTs (abstract data types),
according to Eck (2020), is a set
of possible values and a set of
operations on those values,
without any specification of how
the values are to be represented
or
how the operations are to be
implemented. An ADT specifies
1) what can be stored in the
ADT, 2)
what operations can be done.
ADTs (abstract data types), according to Eck (2020), is a set of possible values and a set of
operations on those values, without any specification of how the values are to be represented
or how the operations are to be implemented. An ADT specifies 1) what can be stored in the
ADT, 2) what operations can be done.

The advantages include:

1.) Abstraction:

the user of an ADT doesn’t need to know or even understand any of the implementation
details of the ADT, which reduces the complexity of the programming task.

2.) Localization of bugs:

if there are bugs either in the representation or implementation of the ADT, the bugs are local
to the ADT, and can’t be caused by code that uses the ADT.

3.) Localization of changes:

if the programmer decides to change the representation of a ADT (i.e, to change the
representation of a set from a linked list to a stack or array), then only the implementation of
the ADT need be changed; code that uses the type is not affected.

4.) Encapsulation

encapsulation or “black boxing” ensures that data cannot be corrupted, and ensures that your
code-base is free of errors

5.) Robustness

Your programs will be robust and have the ability to catch errors and prevent exceptions.

Reference

Chris Harwell, (May 2, 2019). Advantages of ADTs for program modularity. Retrivied from
https://chrisharwell94.medium.com/advantages-of-adts-for-program-modularity-
4449f9f08b07

Eck, D. J. (2020). Introduction to programming using Java, version 8.1.1. Hobart and William
Smith Colleges. http://math.hws.edu/javanotes.

You might also like