You have seen me putting in comments in most of my samples. These not only help other people understand your code but will also help you remember what you were thinking when you revisit your scripts months later to fix something. Comments not only explain your code, but also explain how to use your code or functions that you want others to use.
Python supports a method of creating documentation for your modules known as docstrings. Docstrings are strings written with triple quotes (“””) and can be placed at the top of modules and inside functions. When you type help(moduleName), Python will print some nice documentation using the docstrings that you specified in your module.

Figure 13 - Documenting Your Code
You should try to put docstrings in your code as much as possible. It will save you and your coworkers a lot of time down the road.
