Skip to content

Fluent Python Notes

Here’s the plan: when someone uses a feature you don’t understand, simply shoot them. This is easier than learning something new, and before too long the only living coders will be writing in an easily understood, tiny subset of Python 0.9.6 <wink> - Tim Peters

Running tests:

pytest

Running doctests:

python3 -m doctest example_script.py

Part 1: Data Structures#

1. The Python Data Model#

  • Consistent API of objects called the Python Data Model.
  • A framework of interfaces.
  • Special methods - dunder methods eg. __getitem__

Sources#