Hacker News new | past | comments | ask | show | jobs | submit login

The reason for the low variance in python solution times is a design feature: "there should be one -- and preferably only one -- obvious way to do it" (Guido).

Of course there is often more than one way to do anything in python. For instance, Guido prefers list comprehensions to using map even though both drop down to the C-layer for improved performance whereas iterating/looping generally does not. Most python programmers, however, seem to stay away from the functional programming aspects of python, if their code is any indication.

Although python has the basics of functional programming: map, reduce, lazy evaluation (for some iterators/generators), its support for lambda functions is clumsy and many advanced features (such as monads) are not present in the standard libraries at all. Python lets you experiment with functional programming but that's about it.




what about java's OOP only? why wouldn't the design lower variance?

my take is that java's high variability is caused by its verbosity: more codes = more 'moving parts' = more things that can go wrong

to disprove my theory, give me a verbose language with low variability in solution times




Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact

Search: