Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What % of programming time do you spend debugging? [closed]

Tags:

debugging

What % of programming time do you spend debugging? What do you think are acceptable percentages for certain programming mediums?

like image 274
Ryan Avatar asked Feb 24 '10 12:02

Ryan


People also ask

How much time does a programmer spend on debugging?

Software developers spend 35-50 percent of their time validating and debugging software. The cost of debugging, testing, and verification is estimated to account for 50-75 percent of the total budget of software development projects, amounting to more than $100 billion annually.

What percentage of programming is debugging?

Only half of programming is coding. The other 90% is debugging. : r/ProgrammerHumor.

How many hours should I spend on programming?

On average, you should spend about 2 – 4 hours a day coding. However, efficient coding practice isn't really about the depth of time spent writing or learning codes but rather benchmarked on the individual's consistency over a given time.

Does debugging take longer than coding?

Surprisingly, the debugging process may take significantly more time than writing the code in the first place. A large amount (if not most) of the development of a piece of software goes into debugging and maintaining the code, rather than writing it.


2 Answers

About 90% of my time is spent debugging or refactoring/rewriting code of my coworkers that never worked but still was commited to GIT as "working".

Might be explained by the bad morale in this (quite big) company as a result of poor management.

Managements opinion about my suggestions:

  • Unit Tests: forbidden, take too much time.
  • Development Environment: No spare server and working on live data is no problem, you just have to be careful.
  • QA/Testing: Developers can test on their own, no need for a seperate tester.
  • Object Oriented Programming: Too complex, new programmers won't be able to understand the code fast enough.
  • Written Specs: Take too much time, it's easier to just tell the programmers to create what we need directly.
  • Developer Training: Too expensive and programmers won't be able to work while in the training.
like image 186
Morfildur Avatar answered Sep 30 '22 16:09

Morfildur


Not a lot now that I have lots of unit tests. Unless you count time spent writing tests and fixing failing tests to be debugging time, which I don't really. It's relatively rare now to have to step through code in order to see why a test is failing.

How much time you have to spend debugging depends on the codebase. If it is too high, that is likely a symptom of other problems, e.g. lack of adequate exception handling, logging, testing, repeatability etc. What counts as "Too high" is subjective.

If you do have to debug an error, think about making a failing test before you fix it, so that the error does not recur.

The worst that I have had to work on was a large and complex simulation written entirely without tests. Sometimes it failed in the middle of a run, and to reproduce a crash involved setting a breakpoint, starting the run and waiting half an hour or more. Then make a change and repeat. Don't ever get yourself into that morale-sapping and productivity-destroying situation.

like image 24
3 revs Avatar answered Sep 30 '22 17:09

3 revs