~/talk

A tour of the module itertools

Talkat PyCon Italia 2025 · 2025-05-28..05-31· [python]
slides:none on file

The module contains 20 tools and the talk demonstrates roughly 10 of them, claiming many are lazy like range laziness and work on any iterable. Examples include combinations and permutations for flavor pairs and cones, product to replace nested loops and generate test cases, chain/from_iterable to concatenate files without building large lists, islice to take the first 10 items from a product (used for a battleship bot), pairwise to avoid slice copies, count as an ID generator, and zip_longest filling missing values with None.

AI-written summary · about

  1. 0:00Introduction and laziness
  2. 3:57Module overview and categories
  3. 7:45Combinatorial iterables
  4. 12:38Reshaping iterables
  5. 18:19Infinite iterables
  6. 21:27Filtering iterables
  7. 24:23Complementary tools
  8. 26:28Other tools and conclusion
  9. 28:14Q&A
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.