Re:First Impressions of Python from a Java Developer
by Semiapies on Monday November 08, 2010 @01:53PM
(#1883477)
Mind, this is not unique to Python. It's a bit more irritating in Python because indentation is significant, but I've seen a lot of unindented samples of other languages with correspondingly reduced readability. For some reason, I've most seen such sloppiness in presenting Javascript code.
[ Parent
| on HN ]
Re:First Impressions of Python from a Java Developer
by wvenable on Monday November 08, 2010 @02:10PM
(#1883546)
Yes, but the reduced readability is an easy fix in that case. You can copy the code into an editor and indent based on the braces or have your editor auto-format the code. Badly formatting code in other languages does not change the meaning of the code as it does in Python.
Re:First Impressions of Python from a Java Developer
by Semiapies on Monday November 08, 2010 @02:47PM
(#1883703)
I'm not sure what your point is, as I already acknowledged that in the comment you're responding to, while making it clear that my concern was readability of code examples on a web page. Are you going for a cheap "gotcha"?
Re:First Impressions of Python from a Java Developer
by wvenable on Monday November 08, 2010 @06:03PM
(#1884429)
My point is poor readability of samples in other languages is a really simple fix. I have cut'n'pasted many code samples into editors just to re-intent them for reading. With Python, sadly, it's just not possible to that roboticly.