Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
# Having fun with context managers
from contextlib import contextmanager
def deity():
print 'The Father'
print 'The Holy Ghost'
god = deity()
with god as my_witness:
print 'The Son'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment