Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Most 10x coders deal with it by not using 3rd party libraries, except for ones that are very highly regarded and trusted. These tend to avoid most of the configuration headaches because everyone uses them, so the maintainers get lots of practice in making them easily installable.

It's funny how common wisdom in the software industry is "reuse, don't rebuild", but if you look at projects that are actually successful and developers that are highly regarded, they all have a massive case of NIH syndrome. Google and Microsoft both build all their own software. Mozilla completely reimplemented COM for Gecko. John Resig just got criticized recently because TestSwarm duplicates a lot of the functionality of Selenium Grid. Linus Torvalds wrote his own OS instead of hacking MINIX, and then wrote his own VCS rather than use Subversion or CVS. Chuck Moore wrote everything himself, down to the hardware, which he designed with CAD software he wrote himself in Forth, a language he wrote himself.

If you look at it by numbers, this makes perfect sense. The average library is, by definition, average, so a coder who is way above average can undoubtedly write something better given enough attention to the problem. Plus, many of these super-coders got their reputation by writing lots of code in the first place, which you don't do if you just reuse third-party libraries.

Unfortunately, everyone thinks they're above average, which is why we get such a profusion of libraries in the first place. ;-)



'It's funny how common wisdom in the software industry is "reuse, don't rebuild", but if you look at projects that are actually successful and developers that are highly regarded, they all have a massive case of NIH syndrome.'

Like all other absolute statements, it's wrong, just as the converse ("rebuild, don't reuse") is, and a balance is required.

For context, I do a lot of XMPP work, which is all XML. In the languages I work in, I've gone through all the XMPP libraries that I know of, and found them wanting. I now use some layers I wrote myself directly around Expat. Why? Because nobody but nobody seems to be able to write an XML library that correctly handles namespaces! Which is death when working with XMPP. Yeah, if you hack hard enough you can get around the problem, but especially given the thinness of the usual XMPP libraries and what little they do, it doesn't take much to flip over to negative value.

On the other hand, when I went to write a routine that takes a PNG file of arbitrary size and resizes it to be an avatar, I'd be a damn fool to yell "screw it!" and reimplement a PNG reader.

So, it depends. Factors to consider include the long-term price you'll pay for a sub-optimal library, how close to core it is to what you are doing, whether or not you've ever implemented anything close enough to the library in question that you are really sure you can build something better (sometimes libraries suck because they suck, but sometimes they suck because they solve a hard problem and the "suckage" is actually the hardness of the problem poking out) as it is so easy to end up creating something worse, and, since I deal almost exclusively in open source now, whether you can take most of an existing library and actually bring it up to spec more easily than starting from scratch.

One of my favorite maneuvers, not that I do it often, is to take some rather large library that does what I need but not terribly well, along with a lot of other stuff, and then tear it to shreds in the process of making it do what I want. A coworker of mine recently wanted to do zeroconf autodiscovery, so they started with dhcpcd and started tearing out everything except the use of the dhcp protocol, because it was easier than trying to start their own stuff from scratch. Worked great in less than an hour; I can't imagine what else they could have done in less time, even finding a conventional library, downloading it, and learning how to use it would have taken longer than that.


I mentioned that in the first paragraph, but then later went on to hyperbolize in the quote you pulled out. "Most 10x coders deal with it by not using 3rd party libraries, except for ones that are very highly regarded and trusted."

I do use 3rd-party libraries. I'm a big fan of JQuery, for example - I can't use it in my day job because we literally count bytes when serving JavaScript, but I use it all the time for prototypes and personal projects. But I know that Resig is a top-notch coder, and more importantly, JQuery has had thousands of projects beat on it for a couple of years. If there're corner cases, they've been explored and uncovered, bug reports have been filed, and patches have been made.

Similarly, I use Apache/Lighttpd and MySQL and Django and PIL and BeautifulSoup (though I had some installation issues with PIL, so maybe that's not a great example of a well-tested, well-documented library). But these are pretty well-exercised projects with large userbases: other people have already done the dirty work of discovering all the bugs.

Makes me wonder why anyone would ever use new open source projects, which is essential to getting to the well-tested, well-exercised stage. I think it comes down to need: they'll reach for an imperfect library if the problem is so scary that they don't even want to approach it. So go work on hard problems, and you'll be popular. ;-)


I wasn't trying to criticize, I was expanding upon. (/bloviating/babbling/etc.)


I mostly agree but:

> The average library is, by definition, average

It's not that simple. The average programmer who releases a library is better than the average programmer.


Yes, however a library you didn't write is likely less well-suited to the specific problem you're trying to solve than the one it was originally created for. Also, you won't understand it as well as its creator. And it's likely not written in the same style as you'd have written it.

The benefit of using a library written by an above-average 3rd party is often offset if not negated by the above concerns.


/warning: rant ahead. I'm at work on a Saturday.

I really sympathize with the OP, because I inherited a web based enterprise system that was built using as many open source packages as possible. It appears to be something north of two dozen; some of which I have never heard of. Have you ever tried googling for "barbeque software"? (I found it, barcode scanner.)

I am a big believer in getting your core compancies down cold. I'm in the Java world, so that's a given. If you are serious into business, you must have a good understanding of SQL. I am now going through hell because the previous developer wrote his object hierarchy in java and XML and let Hibernate put his database together. Now I have serious performance problems, along with mysterious bugs.

I see too much of the attitude of adding layers of adding layers of abstraction to allow them to to use the Java mindset. God sakes, people. SQL is way more powerful than Java. Use it. The same thing with JavaScript libraries. Don't pull in a 100K library to get a couple of useful functions. Write them yourselves. Avoid getting caught in a maintenance trap.


with JavaScript libraries. Don't pull in a 100K library to get a couple of useful functions. Write them yourselves. Avoid getting caught in a maintenance trap.

While I agree with a lot of the rest, I'm not sure I understand this part... a 19k library (jQuery) that gives you a single DOM interface that fully takes advantage of JavaScript and works in every major browser is what will keep you out of the maintenance trap, not writing/maintaining that interop code yourself.


Are you sure these are examples of 10x programmers and not 100x programmers?


Personally I think they're the same creature, it's just that 100x programmers happened to work on problems that are more visible to other programmers.

I've noticed quite a few programmers inside Google that are easily the caliber of Resig or Zawinski, but I'd never heard of them outside of Google because they work on closed-source software and don't go around taking credit for their work.


See "Code Reuse Considered Harmful": http://lists.canonical.org/pipermail/kragen-tol/1999-March/0...

Rereading it, I think it was mostly right, but partly wrong. The path to massive programming productivity isn't to rebuild everything from zero; it's to reuse only the right things.


I don't claim to be a 10x programmer, rather I've thought a lot about productivity and programming. In my opinion it's better to develop deep knowledge of a few tools, than spending time learning and futzing with many tools. I've mostly developed this opinion from experience and a Philip Greenspun anecdote that I can't seem to find, that basically goes like "programmers like to grab a bunch of 'best of breed tools,' disappear into the server room to integrate them, only to emerge 2 years later to ask for a $2 million budget increase and another 2 years.


I don't think it's NIH exactly, but a certain laziness and unwillingness to try anything but the simplest(even stupidest) solution. My observations and personal experience indicate that a 10x will reuse formats, languages, and protocols, and they'll use libraries for the purpose of taking advantage of those things.

What you won't see reused is more high-level functionality. That's where a lot of assumptions have to be made about the program's internal structure, and it's where getting too generic and open-ended makes things very complex very quickly.


Right on the money.

I use 3rd party libraries until I hit a tipping point where either the effort to implement is looking to be greater than the effort to simply write the baseline functionality I need from it. The basic idea is to get it to fill in the functionality you need to prove your point and then rewrite it as your needs increase, or if you're like me, are OCD about a consistent code base.

Instead of writing from scratch, I tend to copy and paste whatever I can salvage and build from there, typically refactoring the original code into something new entirely.


I agree with this. I use third party libraries when its not inconvenient to do so. All the complexity and the kitchen sink that comes with a lot of stuff drives me crazy. For example, when I try to use any Java library from Apache I inevitably need to download three or four other libraries that depend on other libraries and so it goes.

Otherwise, I code in my own scripting language and I deploy to my own app server. I'm very productive this way and I'm able to leverage stuff that doesn't suck.


>> Chuck Moore wrote everything himself, down to the hardware, which he designed with CAD software he wrote himself in Forth, a language he wrote himself.

Whoa, I read a bit too fast there and thought for a second that it was true -- Chuck Norris could do anything!




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

Search: