More information about the Underscore mailing list

[_] Python and Ruby differences

Dan Fairs dan.fairs at
Wed Oct 24 09:26:33 BST 2007

> Does anyone know the origins of why python uses whitespace rather
> than some form of blocks/closures like every other programming
> language? There is probably some crazy reason/story somewhere!

I don't know the origins, I'm afraid. However, it's always pointed  
out that you indent anyway in every other language, so Python's  
removal of explicit block delimiters simply improves readability.

For those who are interested, Guido van Rossum's (the creator of  
Python) blog links to this article, dispelling some of the myths  
about Python's whitespace sensitivity. It's moderately technical :)

 From the article:

"So the conclusion is: Python forces you to use indentation that you  
would have used anyway, unless you wanted to obfuscate the structure  
of the program. In other words: Python does not allow to obfuscate  
the structure of a program by using bogus indentations. In my  
opinion, that's a very good thing."


Dan Fairs <dan.fairs at>