Learn Python the Hard Way: A Deceptively Simple Introduction to the Terrifyingly Beautiful World of Computers and Data Science, 5th Edition
by Zed A. Shaw
Exercise 23
Introductory Lists
Most programming languages have some way to store data inside the computer. Some languages only have raw memory locations, but programmers easily make mistakes when that’s the case. In modern languages you’re provided with some core ways to store data called “data structures.” A data structure takes pieces of data (integers, strings, and even other data structures) and organizes them in some useful way. In this exercise we’ll learn about the sequence style of data structures called a "list" or "Array" depending on the language.
Python’s simplest sequence data structure is the list, which is an ordered list of things. You can access the elements of a list randomly, in order, extend it, shrink it, and do most anything ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access