16 ms·
To me, it's not interesting at all to ask who can write a 100-1,000 line program faster in which language. The real interesting question is how efficient develo
by SpikeGronim 16y ago
To me, it's not interesting at all to ask who can write a 100-1,000 line program faster in which language. The real interesting question is how efficient developers are once you're talking about a 100,000 - 1,000,000 line program that has been in development for years. Solving small problems is relatively easy.
- kingkilr 16y agoI'll turn that on it's head. To me the interesting question is: do you need 100,000 or 1,000,000 lines to express the same ideas?
- kbd 16y agoAnd if you assume a relatively stable bug/loc ratio...
- kenjackson 16y agoSo are you saying we don't need emacs?
- ntoshev 16y agoHe is saying an Emacs in Java would be 10x as big.
- kenjackson 16y agoSo he's saying that a Java version of Emacs would be 10 million lines of code long? That's ridiculously unlikely, unless given to monkeys to code -- and even then incompetent monkeys. This is just wishful thinking.
- andrewcooke 16y agoEclipse was 18 million lines in 2008 - http://eclipse.dzone.com/articles/eclipse-ganymede-18-million-li http://eclipse.dzone.com/articles/eclipse-ganymede-18-millio... Obviously it's not a direct comparison, but...
- gphil 16y agoWow, that is the biggest codebase I have ever heard of. Does anyone know of anything bigger than that?
- route66 16y agoI would be surprised if the said 100k-1M LOC programs would not be decomposable eventually into 100-1000 line subunits. The "faster" aspect might be overrated, but in a concise language the 1M-LOC might be reduced significantly or might be more manageable.
- mkramlich 16y agothe point is that what might take 1mil LOC in Java may take only 100k LOC in Python.
- wynand 16y agoPerhaps but I think it depends on who's writing it. I love Python and haven't touched Java in years but my colleagues who use Java seem to write programs that are maybe around 3 times longer (this is a ballpark figure). I get the feeling that programmers that produce gobs of Java code are probably going to do the same thing in Python. A good Fortran programmer can write Fortran in any language :).
- DrJosiah 16y agoThat's basically my opinion too.
- barnaby 16y agoOverly wordy Java coders would still be overly wordy Pythonistas, except the Python culture enforces the "Python is not Java" mentality so they would be corrected on almost every turn, plus the code tutorials and examples from which they learn would be shorter. As a result they would become less verboten very quickly.
- samratjp 16y agoThat and most new-python converts initially don't think in a very functional way. After the "aha" moment of lambda love, the Java ways can be unlearned.
- towndrunk 16y agoSo, I have been working at learning Python (I do Java at my day job). Where can one pick up this "lambda love" quickly? Any links or pointers?
- 16y ago
- samratjp 16y agoEven at that scale, python code readability trumps over almost every other language out there. Compulsory indentation and there's only one way to do this mentality keeps everyone on the same page. So, yeah, that's probably why Google uses python extensively.
- harryh 16y agoGoogle doesn't use python extensively. It's used as scripting glue in a lot of places but there are no actual products written in python. It's all Java and C++.
- samratjp 16y agoYou're right about that. I meant to say that even at larger organizations with big projects, python can succeed.
- stevvooe 16y agoMost of the youtube app servers are all written in python. Whether one considers this glue code is a philosophical question.
- DrJosiah 16y agoThe vast majority is Python (I'm a former 'Tuber). For a while, there was a real-time streaming/playlist/chat thing written in Erlang, but that's been gone for over a year now.
- angusgr 16y agoAre you at liberty to say why the Erlang thing got replaced? (Erlang & Python are my two favourite languages to use, but there are not that many problems I would interchange between them.)
- DrJosiah 16y agoThe Erlang thing didn't get replaced, it got removed. YouTube itself is an interesting project from the inside, though perhaps not that much different from any multi-featured website. Everyone has their own favorite features, their own favorite parts of the site, which they think will become "the next big thing", despite having a few orders of magnitude to go in order to reach the top 5 (which is 99.9% of the traffic). The chat/individual playlist thing was a cute feature, but it had maybe a few hundred concurrent users at any one time. If you consider that the recent Lonely Island video pulled about 3 million views in a 24 hour period, and was less than 1/333rd of YouTube's video views (using the publicly released 1 billion views/day number), you come to the realization that any code that isn't being used heavily, is effectively an unused feature that offers you nothing, and even worse, can't earn the site any money in ad revenue. Heck, I saw micro-communities as "the next big thing" on YouTube, and saw how poorly the original YouTube Groups fulfilled that. I envisioned small-medium sized forums where people would post, rate, and watch videos. I pushed and pushed and pushed until I got a little under a year to work on it, releasing Groups 2.0 in August/September of 2009. I watched how it was being used, got rid of some superfluous features, and pushed out an optional new version for people to use, which became the default on my birthday as my parting gift. Turns out that some code that I was relying on working from another part of the site had broken by another engineer, so they manually made it the default and only version a week or two after I left. Sadly, YouTube Groups is no more, having been turned down on December 1, 2010, code deleted a couple weeks later. A friend and former coworker who had maintained Groups after I left had pointed me off to a WWE fan group with over 100k video posts and a few hundred thousand members (which would be a huge success anywhere else). Since no one was really willing to truly maintain and improve it (I can't blame them, there were some nasty hacks in there), and it wasn't driving as much traffic as even one Lonely Island video, they tossed it. It probably didn't help that I'd ruffled some feathers with the ways I'd pushed for Groups; I'm surprised it lasted even that long. Ah well, many lessons learned, many good memories.
- japherwocky 16y agoI think a 100-1,000 line program is roughly equivalent to a small "feature" in a new product, so I think it's a pretty good metric. Think in terms of the budget of whatever you're building - the python guys delivered in a quarter of the time it will take the Java guys. It's all about solving lots of small problems quickly, imho.
- stcredzero 16y agoSince it's been found that the types in mature dynamic language programs are mostly static after a certain point anyways, why not add optional typing and empirically determine the types at runtime using the same tracing technology tracing JIT VMs use? This would give one the best of both worlds: fast prototyping for initial development, and type safety, added information when refactoring, and additional optimization when the code is mature.
- gcr 16y agoOh, interesting idea. Sorta like how common lisp does it?
- stcredzero 16y agoWell, of course Lisp is already doing it!
- DrJosiah 16y agoThat is sort of the implication with some of the optional type annotations included in Python 3.1 and beyond, fyi.