Personal computing discussed

Moderators: renee, SecretSquirrel, just brew it!

how much you code professionally per year (lines)

< 2000
4 (21%)
2001 - 5000
1 (5%)
5001 - 10000
1 (5%)
10001 - 15000
1 (5%)
> 15000
3 (16%)
i'm too busy working to count lines
4 (21%)
i'm too busy eating cheese to code
5 (26%)
 
Total votes: 19
 
danny e.
Maximum Gerbil
Topic Author
Posts: 4444
Joined: Thu Apr 25, 2002 3:09 pm
Location: Indonesia/Nebraska/Wisconsin

how much do you code?

Fri Jun 23, 2006 9:44 am

from this discussion:
http://techreport.com/ja.zz?id=129344

i decided to bring it in here and see how many other programmers out there average per year. .. but maybe you have an estimate?
so .. for all the coders out there: how much do you estimate you code per year (lines).

--------------------------------------------------

danny e. wrote:
meh. i have programmed over 117,820 lines of code this year and the year is only half over.

I would agree the average is probably around 10,000 - 20,000 a year.

just brew it! wrote:
You've clearly never worked in a large, bureaucratic organization with a significant percentage of marginally competent developers, trying to maintain/enhance a large legacy code base. You'd be amazed at how much that can kill productivity. Even the best and brightest can get dragged down to near zero productivity, because they are spending most of their time chasing bugs created by the putzes on the team, and/or are mired in layer upon layer of software methodology which has been put in place to protect the code base from those same putzes.

Even in a smaller shop, staffed entirely with people who have a clue, it isn't necessarily that simple, depending on the application. I spent several months this past winter not writing code at all. We eventually need to get avionics certification for the system we're building, and consequently had to spend a lot of time making sure we've dotted the 'i's and crossed the 't's on our specifications and design documentation, before we could dive into the hard-core coding phase of the project.

danny e. wrote:
huh? because i guess the average is 10,000 to 20,000 ?

the place i work definitely isnt huge, but its not tiny either. my coding is way above normal simply because i am working on a utility that needs data components for 300+ database tables ... so the 117K + lines of code that i have done is not "normal" code by any means.

just brew it! wrote:
Assuming you mean debugged, documented lines of code, yes, I think 10-20K/year is unrealistically high for an industry average.

I've got no problem with the idea that an experienced, motivated developer who is unencumbered by legacy code or overbearing methodology (such as yourself) could hit the kind of numbers you're quoting. But industry-wide, 10-20K/year just isn't happening IMO. Not even close.

I've worked on large teams where a significant percentage of the developers (I'll guesstimate 25%) had negative productivity. Seriously. This sort of thing is a lot more common than you might think.
 
nerdrage
Graphmaster Gerbil
Posts: 1314
Joined: Thu Mar 06, 2003 2:49 pm
Location: Raleigh, NC

Fri Jun 23, 2006 10:02 am

<2000 lines/year. Probably not even 1000. I work on the "client delivery" team for a company that sells a hosted web service for outsourced HR solutions. We use a standard codebase, which is mostly J2EE with a little XSL/XML mixed in. Most of my work involves customizing the standard product to the client's specifications, so not a whole lot of coding is involved. We tend to spend a lot of our hours gathering and then clarifying requirements, and testing/QA once the coding is complete.
 
Flying Fox
Gerbil God
Posts: 25690
Joined: Mon May 24, 2004 2:19 am
Contact:

Fri Jun 23, 2006 10:43 am

KLOC is not really the one and only measure of productivity. I usually count how many projects and various other accomplishments. Besides, if you refactor code, do you count code that you have written in all those or you just count the outcome?
 
lordT
Darth Gerbil
Posts: 7430
Joined: Fri Nov 25, 2005 2:11 pm
Location: Writing
Contact:

Fri Jun 23, 2006 12:23 pm

Professional coding-None. But the number of lines on my other personal projects amount to around 5000+
 
bitvector
Grand Gerbil Poohbah
Posts: 3293
Joined: Wed Jun 22, 2005 4:39 pm
Location: San Francisco, CA

Fri Jun 23, 2006 12:33 pm

Flying Fox wrote:
KLOC is not really the one and only measure of productivity.

And it's not even a particularly good measure of productivity. In my experience, some of the programmers with the highest line counts simply write bad code and needlessly overcomplicate and replicate things (and often reinvent the wheel... poorly).

Aside from all that, lines of code is heavily influenced by the language used for development. Depending on your needs, 10K lines of C can often be replaced by fewer than 1K lines of a higher level language. Even still, some higher level languages like Java and Ada tend to be quite verbose.

According to sloccount, my stats for the past 2-3 weeks (at my part time job):
Totals grouped by language (dominant language first):
ansic:         2626 (81.99%)
python:         503 (15.70%)
java:            74 (2.31%)
 
mattsteg
Gerbil God
Posts: 15782
Joined: Thu Dec 27, 2001 7:00 pm
Location: Applauding the new/old variable width forums
Contact:

Fri Jun 23, 2006 1:16 pm

I generally hack together a few thousand lines of matlab code to use myself in my work (primarily for data processing and analysis), but it's rarely well documented or significantly maintained. I'll write a hundred lines here, a hundred there, and maybe something like a thousand lines or so a couple of times a year. If you count LaTeX as coding (hey, it's compiled...) then it's a fair bit more.
...
 
dragmor
Grand Gerbil Poohbah
Posts: 3644
Joined: Mon Sep 23, 2002 7:24 pm
Location: Oz

Fri Jun 23, 2006 7:17 pm

For me it depends on mostly on the week and what job I'm doing.

This week was mostly R&D for an upcoming conversion of a DOS program (flex based) to ASP.NET, where we have to maintain the ability to use the whole program with the keyboard only and same flow/useability. I was also looking for a decent grid control. Infragistics seems the most likely target at the moment.

So I've probably written 500 lines of javascript (of which 90% has been thrown away), and 2000 lines of VB.net and html.

I spent the whole week before improving the performance of some mainframe assembler code. The entire code is ~2000 lines, I probably only changed 200 lines and rewrote a standard library function (my fathers old trick, change the file access to remove some of the overhead since its a controlled environment, 131 ops to 27). Ended up cutting the time taken by 53%.

Week before that I was putting a pretty interface onto an Access application. Maybe 200 lines of code and a lot of photoshop work.

Small Companies rock, I would get so bored working on the same project all the time.
SZ87R6/i5 4560 stock/24GB 2333mhz/840 Evo 250GB/Seagate 2TB/ASUS 760GTX/Dell 2711
Rainbows lie in corded knots
While thunder wakes the sleeping crocs.
 
just brew it!
Administrator
Posts: 54500
Joined: Tue Aug 20, 2002 10:51 pm
Location: Somewhere, having a beer

Fri Jun 23, 2006 8:23 pm

I've cranked out several thousand lines over the past few weeks. But that's because we're into the coding phase of the project now, with a reasonably solid set of specifications and design documentation. If I simply extrapolated that rate out for a year it would probably grossly over-estimate my productivity, since we won't be cranking out new code full-bore for the next 12 months.

I'd also like to clarify my position from the original comments thread somewhat, as I think there might've been a bit of a misunderstanding. The part I originally had a problem with was the blanket statement that "the average is probably around 10,000 - 20,000 a year". Assuming you mean debugged, documented lines of new code, I'd say that may be a reasonable average for experienced, competent developers who are lucky enough to spend most of their time actually writing new code.

However, if what you really mean is an industry-wide average across all software develpers, then:

- You need to include the inexperienced and incompetent developers in those stats. There are a lot of them, and they really drag the average down.

- In many organizations, the experienced developers spend only spend a small percentage of their time actually writing new code. A lot of time is spent writing and/or reviewing specifications and design documentation, mentoring less experienced developers, and attending meetings.

- Time spent fixing obscure bugs (whether your own or someone else's) can drag the average down. A particularly nasty one might completely kill your productivity for days.

- In a large, complicated, poorly documented legacy system (these are a lot more common than you might think too), you can literally spend days just getting your bearings in the code. Two weeks of intensive investigation and wading through old code, and then on the last day you spend a couple of hours writing 200 lines of new code to implement that feature someone has asked for. Guess what? Your average productivity over those 2 weeks has been only 20 lines/day.

- In any sizeable project, a fair amount of code inevitably ends up getting shelved, thrown out or rewritten. Are you including that code in your count, or are you only counting code which makes it into a final shipping (or deployed) product?

Factor it all in, and 10-20K/year is starting to look pretty optimistic. And in extreme cases where you get "had" by most (or all) of the above issues, getting down to just 1K/year doesn't seem so far-fetched any more.
Nostalgia isn't what it used to be.
 
Wajo
Gerbil Elite
Posts: 600
Joined: Fri Jun 18, 2004 2:08 am
Location: MX

Fri Jun 23, 2006 10:07 pm

jbi, remember most code written is severly undocumented and sometimes, more complex than it needs to be, which can increase the total ammount of lines coded...

Of course, there is a BIG difference between 1000 lines of high quality, documented code and 1000 lines of C that look like perl :|
Intel Core i7 3770K / 16 GB Kingston HyperX DDR3-1600 / Intel 520 180GB SSD / WD 2TB HDD / Zotac GTX 1060 6GB / Corsair TX650 V2 PSU / Asus Xonar DG
 
bitvector
Grand Gerbil Poohbah
Posts: 3293
Joined: Wed Jun 22, 2005 4:39 pm
Location: San Francisco, CA

Fri Jun 23, 2006 10:31 pm

just brew it! wrote:
- You need to include the inexperienced and incompetent developers in those stats. There are a lot of them, and they really drag the average down.

As I said in my last post, some of them drag the average up... see quadrasort and < 5 element map.

During my several years as a CS TA, I found that the best students often produced consistently shorter and simpler code compared to some of the more... ahem... creative (broken) solutions. Some people just have a knack for taking something fairly straightforward and making it super-complicated. I think part of this has to do with a simply misunderstanding or lack of clarity in thinking about the problem to solve.

Sometimes people are ignorant of existing library functions and spend a lot of code reinventing the wheel poorly. There's also the cut-and-paste ninjas who prefer manual loop unrolling and eschew refactoring to abstract out repeated common functionality. Or programmers who just don't quite get the nifty features of the language they're using. Or maybe they make code-bloating "optimizations" that are simply unwarranted or paranoid (the < 5 element map falls into this category).

This would tend to further support your assertion that good, experienced developers don't write as much code as people think. Obviously good programmers can just write better code quicker, but there is only so much work to be done at a time and, as you mentioned, there are a lot of factors that slow your progress (waiting for others, etc.).

mattsteg wrote:
If you count LaTeX as coding (hey, it's compiled...) then it's a fair bit more.

Well, hey, HTML is interpreted. Both are markup. Although TeX is Turing-complete.

Who is online

Users browsing this forum: No registered users and 14 guests
GZIP: On