doesn’t he weasel out of the responsibility to give clear, logical, verifyable reasons for his position?
Absolutely, if I remember right he leans back on having experienced bad comments more often than helpful ones. John questions this. I think it is close to dogma with Bob on this.
Can you explain that more?
And doesn’t the example with the prime number generation algorithm show clearly that omitting context just does not work for code?
Quote from en.wikipedia.org/…/High-context_and_low-context_c…
High-context cultures often exhibit less-direct verbal and nonverbal communication, utilizing small communication gestures and reading more meaning into these less-direct messages. Low-context cultures do the opposite; direct verbal communication is needed to properly understand a message being communicated…
Now I’m not making a strong claim that Bob and John are from different ends of the context spectrum. However it seems to me that Bob believes there is enough ‘context’ available in code and in coders themselves to communicate all meaning without comments.
Even Bob’s diagram, to help explain the primes algorithm, assumes high context in the reader. It’s lacking any labels or key - we are just supposed to see what he means if we stare hard enough at it. If we are already immersed in the problem space then this might work but its so inefficient for anyone else.
And once we step away from our code for even a short time we are that someone else. We are going to waste a lot of time rediscovering how the algorithm works. A case John makes convincingly I think.
Code cannot replace comments. The primes algorithm avoids division I believe but this is not clear from the code alone. A reader might work this out eventually but a comment saves so much time. Could the code be refactored to clearly express the avoidance of division? Yes there’s probably a way, but imagine how bad that code would read and what a waste of time just to avoid a comment.