Visualizing Abstraction

Jessen T. Havill · 2020

A “black box” that performs an action is called a functional abstraction. The description of a turtle in turtle graphics is an example of an abstract data type (ADT). Just as a functional abstraction describes how to use a function or process without specifying how it works, an abstract data type describes how to use a category of things without necessarily specifying how they work. Explain the difference between an abstract data type and a Python class. In Python, an ADT is implemented with a class, and instances of a class are called objects. The class, such as Turtle, to which an object belongs specifies what data the object has and what methods can be called to access or modify that data. Remember that a class is the “blueprint” for a category of objects, but is not actually an object.

Read the paper · More papers on PaperTik