Chapter 3. Commenting and Style

A whole chapter on commenting? Yes, a whole chapter about comments, and style. Comments are a touchy subject with many programmers. Some think they are a waste of time, while others add so many remarks to their code that you are not sure if there is any code at all.

Commenting deserves a whole chapter because—and I might as well shock you right from the start of the chapter—around 10 percent of a professional Visual Basic program should be comment lines. Therefore, it seems right that about 10 percent of this book be devoted to such a "remarkable" subject.

Before delving deeper into the chapter, let us look at some common ideas about using commenting and style when programming.

The Top 10 Misconceptions about ...

Get Visual Basic® Style Guide, The now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.