Charlie-Boo wrote: > > [...] This is like > trying to figure out someone's computer programs without the specs > (higher level) or documentation (redundant statements that serve only > to clarify by expressing something in a different way.)
Computer programs should be self documenting. Other documentation is either the same as the code and redundant or not the same as the code and confusing.
if x = SOME_CONST then y = y + 1
if x = SOME_CONST then /* x = today's date, * SOME_CONST = my birth date */ y = y + 1 /* increment my age */
if todays_date = MY_BIRTH_DATE then my_age = my_age + 1
(2) is an example of the silly use of the much vaunted comment, (3) is an example of self documenting code. (1) is probably written by someone raised on BASIC, the variables of which were called A, A1, A2, ..., B, B1, ... (or something, I can't be expected to remember).
-- When a true genius appears in the world, you may know him by this sign, that the dunces are all in confederacy against him. Jonathan Swift: Thoughts on Various Subjects, Moral and Diverting