Peng Yu <pengyu...@gmail.com> writes: > > When you use square brackets, you're creating a generator, as in your > > second example. Your first example is a slightly different beast > > called a "generator expression". If you search for that in the docs or > > on the web, you'll find what you want. > > Thanks. Can the documentation be found by `help()` in python?
The ‘help’ command is not intended to provide comprehensive user documentation. Rather, it is intended primarily to provide a reminder of syntax and purpose of specific API. It is not a replacement for having the Python documentation available. -- \ “The history of Western science confirms the aphorism that the | `\ great menace to progress is not ignorance but the illusion of | _o__) knowledge.” —Daniel J. Boorstin, historian, 1914–2004 | Ben Finney -- https://mail.python.org/mailman/listinfo/python-list