Using indentation for blocking
Fredrik Lundh
fredrik at pythonware.com
Fri Sep 10 08:31:05 EDT 1999
mictali <dwaf at my-deja.com> wrote:
> I was just wondering why Python was designed to use whitespace as the
> block seperators instead of hard indicators (such as {} in C).
this is, of course, a FAQ:
http://www.python.org/doc/FAQ.html#6.2
(also see any of the many threads on this topic in
the newsgroup archives. and yes, you can control
whitespace in XML and SGML -- after all, people
have written Python programming books in such
languages ;-)
</F>
"We will perhaps eventually be writing only small
modules which are identified by name as they are
used to build larger ones, so that devices like
indentation, rather than delimiters, might become
feasible for expressing local structure in the source
language."
-- Donald E. Knuth, "Structured Programming with goto
Statements", Computing Surveys, Vol 6 No 4, Dec. 1974
More information about the Python-list
mailing list