On Sat, Jul 27, 2013 at 2:13 PM, Albert van der Horst <alb...@spenarnc.xs4all.nl> wrote: > If the code is really tidy, it is possible to understand a function > using only the *documentation* (not the code itself) of any function > or data it uses.
I'd broaden that slightly to the function's signature, which consists of the declaration line and any associated comments (which in Python should be in the docstring). The docstring kinda violates this concept, but what I generally try to explain is that you should be able to understand a function without reading any of the indented content. ChrisA -- http://mail.python.org/mailman/listinfo/python-list