~/talk

Fun with Python's newer tools

Talkat EuroPython 2011 · 2011-06-20..06-26· [python]
slides:none on file

Shows concrete new tools and exact code behaviors: use collections.Counter.most_common(50) to get top 50 words (Hamlet example) and combine counters with addition while noting subtraction can produce negatives unless you use saturating logic; use collections.namedtuple plus a ._replace prototype pattern for readable defaults and zero memory overhead; use functools.lru_cache(maxsize=100) to bound caches (fib(100) reduces calls to ~101); new str.format features include thousand separators and attribute/index access.

AI-written summary · about

  1. 0:00Intro
  2. 7:57Counter
  3. 17:03Tuples
  4. 21:41Test results
  5. 25:42API design
  6. 29:52Deal structure
  7. 30:57Default values
  8. 32:44Uniques
  9. 34:35Color Palette
  10. 36:32Cash
  11. 41:02Dynamic Programming
  12. 44:06Torsion
  13. 44:48Count
  14. 46:14String Formatting
  15. 53:48Subtract
~/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.