Containers

Containers are any object that holds an arbitrary number of other objects. Strictly speaking, in the Python Standard Library we found the following containers:

  1. Tuples.
  2. Lists.
  3. Sets.
  4. Dictionaries.

However, extrapolating the idea that any thing in Python is an Object, we can also consider the following structures as containers:

  1. Bytes.
  2. Bytearrays.
  3. Arrays.

Finally, notice that programmers can define their own container structures.


In [ ]: