Commenting your code

Associate
Joined
2 Sep 2007
Posts
2,001
I'm going to be working on some fairly big projects soon and one of the things that popped into my mind what is the best method for commenting. Full detailed header at the top of the file / page? For C# developers out there do you use specially marked comments to produce XML files?

What brought me onto this is a guy in work has gone off sick, it could be long term. I was asked to fix a few bugs in one of his apps, none of the code was commented! The variable names weren't great either. It got to the point I just could not work with the code so we have had to pull the project until he comes back. It made me look like a fool and managers, etc don't understand the problems it can cause by him not commenting.

It also made me realise how important is to write good comments are use descriptive variables, etc.

What do you think?
 
Back
Top Bottom