Live data from Hacker News

Mythical man month: 10 lines per developer day

blog.ndepend.com

151–160 of 212 posts

Re: Mythical man month: 10 lines per developer day

#151

Earlier quoted context omitted.

From the sounds of it that also includes a decent amount of greenfield work. I don't have hard figures to easily consult but I'd guess that I'm at about your average in total, but then on the days when I'm refactoring/debugging existing stuff, honestly it could be like 3 lines a day, or 5, or just planning/sketching something out. It's like the old mechanic trope. It's not hard to replace a bolt, what's hard is knowi…

This "LOC as a proxy for productivity" metric seems so much harder to measure in a useful way on brownfield work. On my most productive (in my own estimation) brownfield days in recent memory, the codebase would generally shrink by several hundred LOC. I also find that a huge factor in my code production rate on brownfield projects might not have much to do with me, because it's factors like, "Is the code well-docume…

> I should never bother to spend an extra hour on making it more maintainable if I expect that the cost of that decision will be born by one of my teammates.

If you want to be a team lead, though, or even just have people follow your lead, I find that not only do you want to worry about these costs, but you need to talk openly about them, and be seen addressing it. Most devs follow the ones they trust, no matter what title they have.

On all the projects where we tried to build people up instead of get shit done, we were consistently getting more shit done at the two year mark, if not sooner. Any idiot can ship a version 1.0.0, but it takes some talent (and luck) to ship version 2.3.0

From what I’ve seen, Postgres followed a similar model, and if you look at the performance benchmarks over time, it has progressively narrowed the gap with each major release. That kind of momentum is something worth sacrificing for.

Re: Mythical man month: 10 lines per developer day

#152
post #97

I did some trivial math. Redis is composed of 100k lines of code, I wrote at least 70k of that in 10 years. I never work more than 5 days per week and I take 1 month of vacations every year, so assuming I work 22 days every month for 11 months: 70000/(22*11*10) = ~29 LOC / day Which is not too far from 10. There are days where I write 300-500 LOC, but I guess that a lot of work went into rewriting stuff and fixing bu…

Just curious, do you still code in vacation days?

Re: Mythical man month: 10 lines per developer day

#153

Earlier quoted context omitted.

Some of my favourite days on the job is when you remove lines of code. Does that metric go against LOC/written?

Reminds me of https://www.folklore.org/StoryView.py?story=Negative_2000_Li... I once had a senior manager who insisted that developers made at least one commit a day (an internal GitHub like tool gamified this: number of lines committed since last month / top committers in the team etc), and those that didn't, had to up their game . It was frustrating to say the least as this was not the only metric . There were a ha…

If you do work in progress (wip) branches where you're not concerned with breaking the build and then rewrite the history to not break the build after (counts as new commits) this becomes more viable.

Also encourages testing work to be formally coded and just done interactively. If a test is good enough to compile, commit it as work in progress even if it has a bug and/or incomplete if you've reached a good point you'll like to build upon. Make a tweak, compiles, commit it.

If you've spent most of your day writing a test, but it's complicated and will require even more work before you'd even try to compile and run, commit it WIP before going home.

Re: Mythical man month: 10 lines per developer day

#154
post #15

Earlier quoted context omitted.

At one job, I replaced a 10k LOC class with a 20 line function which probably took me to a net negative loc count for that job.

I would love to hear more details on this one

Not the parent, but I once inherited a bunch of tools that used the same tracing function. Akin to dtrace. 6 people wrote 6 tools over different domains all with their own post-processing, filtering, formatting, etc...

It was a support nightmare, so we built a common library and collapsed the code base by 70%. Each tool was probably in the -8k eslocs range. Thankfully it wasnt c++.

Re: Mythical man month: 10 lines per developer day

#155

Am I mad? Did anybody actually read the article? Why is everybody piling on LoC/day when the article is about average LoC over a period of time and how it correlates to the work you're doing and what a realistic average LoC might look like for a sane project. From this point of view, it doesn't matter at all if you deleted 20k lines and have a negative LoC for the day. That's missing the forest for the trees.

[deleted]

Re: Mythical man month: 10 lines per developer day

#156

Am I mad? Did anybody actually read the article? Why is everybody piling on LoC/day when the article is about average LoC over a period of time and how it correlates to the work you're doing and what a realistic average LoC might look like for a sane project. From this point of view, it doesn't matter at all if you deleted 20k lines and have a negative LoC for the day. That's missing the forest for the trees.

C’mon man you should know better than that by now. Here on HN you only read the headline. Nobody actually reads the article. At most you read a few comments to get the gist of what people think the article might be about.

Re: Mythical man month: 10 lines per developer day

#157

Earlier quoted context omitted.

From the sounds of it that also includes a decent amount of greenfield work. I don't have hard figures to easily consult but I'd guess that I'm at about your average in total, but then on the days when I'm refactoring/debugging existing stuff, honestly it could be like 3 lines a day, or 5, or just planning/sketching something out. It's like the old mechanic trope. It's not hard to replace a bolt, what's hard is knowi…

This "LOC as a proxy for productivity" metric seems so much harder to measure in a useful way on brownfield work. On my most productive (in my own estimation) brownfield days in recent memory, the codebase would generally shrink by several hundred LOC. I also find that a huge factor in my code production rate on brownfield projects might not have much to do with me, because it's factors like, "Is the code well-docume…

I am about to rewrite something (different cloud, blabla) and if I do a good job I think the program’s LOC will go down by about 25%, the unit testing LOC will go up by maybe 50%, and maybe 50% of each will be the same old logic while the other half will be new logic.

I have no idea how I would try to count that if I wanted to measure “productivity.”

Re: Mythical man month: 10 lines per developer day

#159
post #60
post #40

Earlier quoted context omitted.

When you refactor code you do not deliver value to customers.. You do though, by reducing the future cost of delivering features. That has tremendous value. Find a company that sees good engineering as a long term investment rather than a short term way of extracting money from customers and you'll enjoy software development a lot more.

Again that isn't customer facing value. Users do not care about the costs of your business, I cannot understand how so many developers don't seem to understand the basic premise of b2c relationships. At best it's the proposition of future benefits and those benefits are all to the company not the customer.

if there's a feature i want as a customer, i do care if i can get that in two months vs six months vs a year. i also care that it's stable.

reputation and trust are hard to measure, and the effect is delayed. unless you have the killer app or feature, with the internet now, word will get out. many a company has tanked their reputation.

iteration speed also makes you vulnerable to be leapfrogged. Azure vs AWS seems to me to be this. a lot of Azure stuff is great now, some of that is hindsight, but real innovation at AWS is also rare. their developer tools, aka code*, are completely underwhelming. as is cloudwatch. ec2, s3, dynamo, and general lock-in are just enough to keep a lot of people.... for now.

Re: Mythical man month: 10 lines per developer day

#160

Earlier quoted context omitted.

At one job, I replaced a 10k LOC class with a 20 line function which probably took me to a net negative loc count for that job.

This issue can easily be fixed by switching from delta LOC to the size of the git diff (number of lines changed). The big problem with this strategy is the huge difference between 10 lines of carefully engineered algorithm code and 10,000 lines of blah API calls and boilerplate. I can write API calls and boilerplate as fast as I can type.

> I can write API calls and boilerplate as fast as I can type.

I can write boilerplate much much faster than I can type, either I or the community have scripted that shit :D

Post reply on HN