Press "Enter" to skip to content

Suggestions on Answering Online Programming Questions

I started writing online programming guides over seven years ago – many of them for beginner programmers.

Over the years, that’s led to more than two thousand comments on my sites, with quite a few of them asking for help with bugs.

These are the things I try to keep in mind when answering programming questions.

 

  • Avoid saying “you”, “your”, and “I”
    • Talk about the code, not the coder.
    • For example, replace:
      • “You need to rename the variable” with “Rename the variable”
      • “Your function…” with “The function…”
      • “I would…” with “Another possible way…”
    • Depersonalizing the answer reduces the chance the questioner will feel belittled.
  • Eliminate “should” and “shouldn’t”, when used like “You should” or “You shouldn’t have”
    • It is OK to use it for things like, “These changes should fix the problem”
  • Eliminate, or at least reduce, pronouns
    • A reply to a programming question may involve talking about several classes, functions, variables, etc. The person reading the reply may not know what “it/them/those” refer to.
  • Include the “why” in the answer, not just the “how” or “what”
    • Some people only care about solving the immediate problem. But many people will want to know why the problem occurred and how, or why, the solution solves the problem.
  • At the end of the response, check for clarity
    • Phrase it like, “Let me know if the answer isn’t clear, or doesn’t work” – not, “Let me know if you didn’t understand that, or if you can’t implement it”
  • Update the resource, when possible
    • If one person asks a question about some online documentation, the odds are good several other people will have the same question. When possible, update the documentation.
      • Save future readers time and frustration – and save yourself time too.

 

Please share your ideas on how to provide better answers to online programming questions.

Leave a Reply

Your email address will not be published. Required fields are marked *