Some design patterns, in Python flavor