3 ms·
> The number of lines of code that a programmer can write in a month tends to be a constant independent of language Says who? Ignoring the fact that LoC is a
by gdp 17y ago
> The number of lines of code that a programmer can write in a month tends to be a constant independent of language
Says who? Ignoring the fact that LoC is a terrible metric for measuring anything except the amount of paper it would require to print the program, I think it would be very hard to use it to quantify how much you will accomplish. Your (implied) assertion that you will not just accomplish less, but accomplish between a half and a fifth as much in Java as in Python is even more outlandish. I can't imagine you have any evidence to support this?
> Stay away from Java; everything is too damned complicated
What is this supposed to mean? That the hundreds of thousands of people who make their livings from doing web development with Java and being competent Java programmers are either stupid (for not programming in Python), or super-smart (because they can grok Java)? This is pretty absurd. Java is no better and no worse than pretty much any other language in wide-spread use. To its benefit, it has extensive library support for pretty much everything under the sun, and all the enterprise features which would make it relatively painless to do a whole heap of things that would become very difficult in almost any other language.
Really, I think you should refrain from giving advice on specific programming languages if you are just going to resort to complete and utter nonsense to provide comparisons.
- silentbicycle 17y agoThe argument that lines of code is constant across languages is usually associated with Fred Brooks's _The Mythical Man Month_. I don't buy it, either. (Sometimes there is the added restriction of "lines of debugged code". That may be more likely.) Here is a study of how lines of code produced annually differs across languages in a collection of open-source projects: http://sequoia.cs.byu.edu/files/pubs/Delorey2007.pdf http://sequoia.cs.byu.edu/files/pubs/Delorey2007.pdf Of course, the correlation between lines of code and "productivity" is pretty nebulous. (Copy-and-paste programming is the most obvious example of a negative correlation.) LoC is an easy thing to measure, but not necessarily useful.
- russell 17y agoAs far as I know, the statement about lines of code was first stated by Fernando Corbato http://en.wikipedia.org/wiki/Fernando_Corbat%C3%B3 http://en.wikipedia.org/wiki/Fernando_Corbat%C3%B3 (Corbato's Law). "It's our experience that regardless of whether one is dealing with assembly language or compiler language, the number of debugged lines of source code per day is about the same! [http://web.archive.org/web/20080206153039/http://home.nycap.rr.com/pflass/PLI/plisprg.html http://web.archive.org/web/20080206153039/http://home.nycap....] Python is generally considered to be 2 or 3 times as expressive as Java. I did some estimation on a compiler implementation in C++ and arrived at the conclusion that it could have been done in 20% as much Python.
- silentbicycle 17y agoThanks for the source. It was probably more true then - the then-unimaginable resources available now allow very different trade-offs in language design. (FWIW, OCaml is probably a better language for compiler writing. It hits all its strengths. Failing that, I'd still rather do one in Python or Lua than C, though.)
- russell 17y ago>What is this supposed to mean? ... I didn't say anything about the intelligence of Java programmers. Like everywhere else some are brilliant and some are dumb as hammers. When I said "everything is too damned complicated", I was thinking of Java Web development which has a proliferation of one-size-fits-all frameworks which encourage bloated implementations. It could be that I have blundered into a tiny swamp and everywhere else is sweetness and light, but I dont think so.
- gdp 17y agoI would be very careful not to write off an entire field just because you consider it difficult or complicated. It has its place and purpose, and the complexity is not just for show. It's not "one size fits all", it's just that the minimum size at which it might become useful is probably larger than that of many of the interpreted, dynamic web languages and frameworks that are popular these days. For example, I would much rather maintain a Java-based web application than a PHP-based web application.