Live data from Hacker News

Alan Cooper on the “10x” Programmer

twitter.com

61–70 of 71 posts

Re: Alan Cooper on the “10x” Programmer

#61

Earlier quoted context omitted.

Fiction or non-fiction writing. The difference between Terry Brooks and the average wannabe fantasy author is enormous and the difference between him and JRR Tolkien is greater again. Mathematics. Terence Tao is as far ahead of the average Math professor as they are of the average high school Math teacher. Law. If you give the average lawyer twenty times as much time and all the research resources of a partner at Ska…

Add carpentry or vehicle technician to that list. All jobs where you have some sort of choice on how and what to do and motoric aptitude leads to high variance in skills. The big difference is maybe that bad vehicle technicians are singled out by the boss or customers and quit? While neither the boss or customer can pinpoint a single programmer.

I think this boils down to literally any arbitrary skill based activity. Unless the output is heavily dependent on RNG, there will always be someone who is orders of magnitude better than the average person.

Re: Alan Cooper on the “10x” Programmer

#62

Here are some indicators I've seen from 10x and 100x: The 10x person fits very well in their organization. They are admired by upper-management for their ability to quickly comprehend, estimate, and deliver solutions to problems. They mentor everyone that asks or needs help. They provide 95% test coverage on all code. They show up for work well dressed, clean-cut, and on-time every day. Their code isn't 'brilliant' b…

in my experience, 80% coverage is about the correct number, but then those same lines of code are being covered over and over again for each major business use case.

Bumping the test coverage up past 90% definitely has lines re-run multiple times, with core logic even being re-executed possibly hundreds of times. This is absolutely ok! Your main purpose of writing tests is to make sure when you change business logic that a test will point you to the exact spot. If you commented out any single line of business logic; a test should fail.

I understand that this may seem crazy if you are used to 80% coverage, however there are subtle ways to build your unit/integration/feature/security/performance tests where you only pin your public api, and code changes to the internals don't break the tests, and the test suites only have minimal (necessary) overlap. This is test engineering and it takes about a decade of TDD to be comfortable with.

I would have said 100% test coverage for 100x but that last 1% isn't worth it. Some things just can't be tested without altering the public interface of your code JUST to accommodate the test, or they require some crazy significant re-work of the code that makes it hard to follow, or you have a module with a crazy way of interfacing with it that makes testing a specific part extremely difficult, or it's code that doesn't really need a test (like a log statement).

Side note: 99% test coverage isn't typical but is absolutely necessary if you have automatic patch-management solutions in place and are striving towards zero-defect code. How comfortable would you be pushing to production after bumping the major version of your platform and seeing your test suite pass? Having 99% confidence in this situation is a good thing and saves you time in the long run.

Re: Alan Cooper on the “10x” Programmer

#63
post #38

As an experienced programmer - if you really want to improve productivity 10 times, find the junior programmers in your team, empower them, give your advice when asked, shut up when not being asked, tell them they can do that hard task and help them out when they have problems. Be a decent human being. Then watch with pride as they grow in amazingly quick time. Oh - and just work for a company, that honors when you'r…

I'd argue that programming, like any other human endeavor, has always been teamwork.

In a sense, every programmer is a member of a global, mostly remote, asynchronous team of every person who contributed to the hardware, software, documentation, and theoretical foundations upon which the programmer depends.

Re: Alan Cooper on the “10x” Programmer

#64
post #47

I remember once being asked during a phone-screen how many lines of code I had written. Ever. Some of those things were on classified systems years ago, there is no way I'm going to remember that or even be able to look that up any more. Why would I ever log "wrote a net-worth of xyz lines of code today" for a personal record? I've never worked for anybody who had that as a metric but apparently I had a chance to now…

It was probably just a question testing your ability to estimate. Of the “how many manholes are in Seattle” ilk.

https://www.youtube.com/watch?v=sxhKMuDJ_E8

Re: Alan Cooper on the “10x” Programmer

#65
post #7

One interesting twist is that some problems are completely intractable for most programmers. I mean that they cannot produce a working solution no matter how much time or effort they use, or if they do it's so riddled with bugs it's practically useless. Thus it follows that for certain tasks there are "∞x" programmers. Therefore there are absolutely "10x" programmers as well, which fits in with my subjective experien…

[deleted]

Re: Alan Cooper on the “10x” Programmer

#66

All I can say is, it’s been my subjective experience that competence and productivity are really variable. Some people at my company can produce beautiful, working, end to end solutions for complex problems in the time it takes others to grind out trivial maintenance tickets. Everyone knows who they are. Programmers are not basically all the same, and it’s worth thinking about the nature of the differences if you wan…

10x programmers can hit a target no one else can see. This is true for 10x persons of all types in all endeavours, not just programmers. In this mode they are more artists than technicians. Compelled by vision from an overflowing sacred gift outpacing its faithful servant. Conventions and norms are not designed for this. Those who push beyond the bounds by definition cannot be bound by them. If you want to maximize their productivity, provide them with supporting infrastructure and surround them with brilliant editors to optimize this process and integrate their vision.

Re: Alan Cooper on the “10x” Programmer

#67
post #19

After working with ~ 30 odd programmers, I would probably classify myself as a 10x. I think a good chunk of HN'ers are 10x, with imposter syndrome of course. 1. Patience - I have the patience to sit through and fix a bug. Googling it, reading the source ... this is fun for me. 1x programmers give up very often and very soon. They either blame others, feel pity for themselves for not figuring it out or hate the comput…

This is one of the most profoundly sad--as in, generates genuine pathos--posts I've ever read on the internet. Planting "egoless" square next to "your ideology is a mess" and clearly flagging that you'd rather have the chance to bully beginners than come to an accord with fellow professionals who might not lick your boots the second you walk through the door. While assuming--with no grounds, but you already know that--that somehow those poor benighted "1x programmers" don't have the patience to understand and fix bugs.

This attitude is gross and demeans you and those around you. Worse, even by the standards you spout off about: in my experience it is also and without exception the attitude of someone who is not a "10x programmer" but somewhere in the negatives, causing needless and constant churn for the sake of looking smart.

I truly hope, a few years down the line, you have cause to remember that post with regret because you've grown out of that phase of your development as a professional and as an empathic person.

Re: Alan Cooper on the “10x” Programmer

#68

Here are some indicators I've seen from 10x and 100x: The 10x person fits very well in their organization. They are admired by upper-management for their ability to quickly comprehend, estimate, and deliver solutions to problems. They mentor everyone that asks or needs help. They provide 95% test coverage on all code. They show up for work well dressed, clean-cut, and on-time every day. Their code isn't 'brilliant' b…

in my experience, 80% coverage is about the correct number, but then those same lines of code are being covered over and over again for each major business use case.

I begin to relax around 85%.

It’s perfectly possible for a project to hit 85% without much untoward going on. Running the code and testing the code are not the same, and as the numbers go up I tend to find shenanigans.

I’d rather have an honest 85% than any dishonest number you could want. My butt starts to pucker again above 95%, because it’s all lies.

There also comes a point where running certain tests by hand is faster or more reliable than having a test for it. False positives (failing tests) are expensive, and in a way that is often counted poorly.

For a start, a false positive doesn’t cost the time of the test, it costs the time of the entire test suite times three - the one you wasted, the one you do over, and time between getting a failure and noticing the failure.

It also costs trust in the tools. Red tests become untrusted, which really hurts when you have a test that has false negatives. People become conditioned to hit the run button again without understanding the error, which then blows up farther down the line, possibly in production.

Re: Alan Cooper on the “10x” Programmer

#69
post #68

Earlier quoted context omitted.

in my experience, 80% coverage is about the correct number, but then those same lines of code are being covered over and over again for each major business use case.

I begin to relax around 85%. It’s perfectly possible for a project to hit 85% without much untoward going on. Running the code and testing the code are not the same, and as the numbers go up I tend to find shenanigans. I’d rather have an honest 85% than any dishonest number you could want. My butt starts to pucker again above 95%, because it’s all lies. There also comes a point where running certain tests by hand is…

> My butt starts to pucker again above 95%, because it’s all lies.

With the way you are describing false-positives; it sounds like most of your tests are written as integration or feature specs. Exercising the UI at 95% coverage is insane (maybe that is why you said it's all lies). You will definitely be pulling your hair out with false-positives and with a large enough project you'll never get it 100% passing each day.

The answer here is to shift your tests from the UI or integration level down to unit tests. You should test at the function or model level with unit tests to pin all possible execution paths, then perform a sanity check test in the UI. For example; exhaustively test your login module at the unit level, then perform a sanity check at the UI level. Moving exhaustive tests down to the function or unit level increases test speed because you don't have to load or render the UI to perform the tests (which also eliminates most classes of false-positive tests).

If you or your team have issues with false-positives at the unit level then something isn't right with your test harness, OR you need to git-blame to identify the person on your team that needs some mentoring.

Re: Alan Cooper on the “10x” Programmer

#70
post #68

Earlier quoted context omitted.

I begin to relax around 85%. It’s perfectly possible for a project to hit 85% without much untoward going on. Running the code and testing the code are not the same, and as the numbers go up I tend to find shenanigans. I’d rather have an honest 85% than any dishonest number you could want. My butt starts to pucker again above 95%, because it’s all lies. There also comes a point where running certain tests by hand is…

> My butt starts to pucker again above 95%, because it’s all lies. With the way you are describing false-positives; it sounds like most of your tests are written as integration or feature specs. Exercising the UI at 95% coverage is insane (maybe that is why you said it's all lies). You will definitely be pulling your hair out with false-positives and with a large enough project you'll never get it 100% passing each d…

Testing is hard. Most of the people who tell you otherwise are full of... bravado. Sometimes they have the worst tests.

When I started working with more dynamic languages I took comfort in the promises from TDD folks that you can write tests to cover all of these things, but I've seen how tests are written in practice and it's not good. I've met maybe ten people in twenty years who are really competent at writing bulletproof tests (as in, "You wrote tests for that? Enough said" versus Trust but Verify) and I am not at the top of that list. Frequently enough, I find eyerollers that have my name by them in the commit history.

I'm not saying I'm ready to go back to static languages because of this, but I will say that I see evidence for hope on the static analysis side for once in a very long time.

As you say, the problem is often discerning between unit tests and functional tests. Some people clearly can't tell the difference, but a number of people have confessed discomfort at writing unit tests (something about my frank communication style seems to invite people to share their fears with me, and I hear things that the "everything is great" people don't due to self-censorship). That these unit tests seem juvenile, pedestrian. Remedial. But to my mind that's the point. The cognitive load of determining why I just caused a bunch of tests to go red should be near zero, since I'm still trying to keep my head wrapped around the new code I'm in the midst of writing.

For about as long as I've been writing tests I've worked with people who think writing their own mocks or helper functions in tests is a good use of time. They take some work, so once you have them working they write five more tests that use them. The poor SOB who gets a red test six months from now has no idea what's going on.

Worse, adding more to these mocks may cause some of the tests to be evergreen, and others to be required (deleting test 1 makes test 3 fail). Which is only discovered when a customer complains about bugs and you say, "wait, don't we have tests for this?" The tests are coupled which is bad juju. Every test should be capable of being run in isolation (debugging your tests!)

Often the first thing I do is rip this mess out and winnow the mocks down to the one, two, or three calls that actually need, so each test can be taken at face value. I also replace a lot of ten line tests with more four line, transitive tests (if A->B and B->C, then A->C.) Then I remove any coupling between the input and output that wasn't fixed by doing that (once a month almost, I find a test whose assertion boils down to expect(a).toEqual(a)). And the utility functions get split up into matchers with much more diagnostic data added in, and a bunch of incidentals taken out.

Effectively what we are doing versus languages where writing the code up front requires more thought, is that we are marking stories as done that aren't properly done for weeks, months, or years. It's a bit of knowledge that makes me uncomfortable. I have a lot easier time hiding that discomfort with people whose position in the org chart implies that they are still learning, and quite a time being constructive to the braggadocios. It's a lot of emotional labor and it's taxing.

Post reply on HN