I have been arguing with a friend about the necessity of comments, and the efficiency of different comment styles. The argument ended quite fast, as we could not find any research - or essay - that support either claim.
Has any serious research been conducted regarding the efficiency of different commenting styles? If so, what has it shown? I'm mainly interested with:
- Length (I think that comments longer than a tweet are never read)
- Type (I strongly favor comments that are actual code samples, explaining how to call a method)
- Location (As a separate line? at the end of the line?)