Why indentation is use to denote block of code?

TerryP bigboss1964 at gmail.com
Mon Sep 14 00:43:49 EDT 2009


On Sep 13, 10:12 pm, Peng Yu <pengyu... at gmail.com> wrote:
> Hi,
>
> I want to understand why python use indentation to denote block of
> code. What are the advantages of it? Is there a style in python to
> denote a block of code the same as that of C++ (with '{}')?
>
> One disadvantage of using indentation to denote a block of code is
> that the runtime to automatically indent a python code would be about
> a few times more than the runtime to automatically indent a C++ code
> of the same length (both are in vim).
>
> Regards,
> Peng

Not to be omega-rude and disrespectful, but if you have to ask such a
question -- you are either to stupid a programmer to warrant any
intellectual response, or are just interested in wasting peoples
bandwidth.

The advantages and disadvantages of the white space thing, is
generally self evident: which is likely by design in my opinion.

--
A fairly language independent programmer.



More information about the Python-list mailing list