CHAPTER 13

Abstract data types

Algorithms + Data Structures = Programs

Niklaus WirthTextbook title (1976)

THROUGHOUT this book, we have stressed the importance of both functional and data abstractions in problem solving. By decomposing algorithms into groups of functional abstractions, each implemented by a Python function, we have been able to more easily solve complex problems. Each functional abstraction provides a solution to a subproblem that we can use to solve our overall problem, without having to worry about how it works.

We have also made extensive use of a variety of data abstractions, called abstract data types (ADTs), such as turtles, strings, lists, and dictionaries. Each ADT is defined by the information it can store and a set ...

Get Discovering Computer Science now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.