PythonCert
5.0
  • Topic Notes
  • Exercises
  • Supplemental Materials
  • Resources for Specific Python Topics
PythonCert
  • Docs »
  • Session 3: Context Managers, Itertools and functools
  • View page source

Session 3: Context Managers, Itertools and functools¶

Reading¶

Context Managers

Supplemental Readings¶

Context Managers¶

Fluent Python: Chapter 15: Context Managers and else Blocks

https://jeffknupp.com/blog/2016/03/07/python-with-context-managers/

https://pymotw.com/3/contextlib/

https://docs.python.org/3/library/contextlib.html

Itertools¶

http://jmduke.com/posts/a-gentle-introduction-to-itertools/

https://pymotw.com/3/itertools/

http://www.diveintopython3.net/advanced-iterators.html

Functools¶

https://pymotw.com/2/functools/

http://www.pydanny.com/python-partials-are-fun.html

Exercises¶

A Couple Handy Context Managers

Optional:

lambda and keyword Magic


© Copyright 2017, University of Washington, Natasha Aleksandrova, Christopher Barker, Brian Dorsey, Cris Ewing, Christy Heaton, Jon Jacky, Maria McKinley, Andy Miles, Rick Riehle, Joseph Schilz, Joseph Sheedy, Hosung Song. Creative Commons Attribution-ShareAlike 3.0 license

Built with Sphinx using a theme provided by Read the Docs.