After reading the article, How to Ask Questions the Smart Way, by Eric Steven Raymond, I felt armed with new tools for entering the world of crowd sourced help with technical issues. Although I’ve never asked a question on stack overflow, I’ve turned to the archived answers hundreds of times when I run across issues that have stumped me and have almost always been able to find the answers that I’ve needed, eventually.
I think that word, “eventually”, is the key to this concept of asking smart questions. Raymond talked about the importance of being precise in the question often, because that helps the expert with his or her answer, but it is also important for the people who follow with the same question. When looking for examples of well asked questions, I had this thought in mind, and since stack overflow has a rating system, I went straight to the list of most upvoted questions to see the success stories.
Following a short perusal, I landed on a question that stuck out to me. This question can be found here, but I will not copy and paste the entire question to this essay because it was long, with multiple parts and more than a little code. The writer asks, “Why is it faster to process a sorted array than an unsorted array?” He or she then goes on to explain, Here is a piece of C++ code that seems very peculiar. For some strange reason, sorting the data miraculously makes the code almost six times faster.” One of the topics that Eric Raymond covered was the importance of not trying to explain what you think is causing the problem, but rather just to explain in detail what issues you are having and what you have tried to fix it, and this asker does just that. They post the code, then explain that they thought it may have been an issue with a specific language or compiler, and that they have tried changing that variable. Then, finally, they outline the exact questions that they have rather than just leaving it as some vague, open-ended question. Furthermore, the writer of the question poses their query in a manner that makes them sound intelligent and interested in the technical details of the subject area.
The answer that followed was highly detailed and one that I found interesting even though I had not actually been searching for the answer myself. The responder offered an analogy of train trying to predict which way they were going to turn at a junction to present branch prediction in an approachable way. I believe that this highly detailed answer was given because the question was asked in a way that piqued the interest of the community and made them want to help solve this problem.
Yet, this success story is not the experience shared by all everyone who come to stack overflow seeking assistance. All too often when I’ve been searching for answers, I come across responses to questions that say things like try google (in one form or another), annoyance at duplicate questions, posts in the wrong area of the forum or site, or no responses at all. Since there are thousands upon thousands of examples of highly helpful individuals on stack overflow, the reasons for these negative responses are almost certainly due to the failure of the questioner to ask in a smart way.
When looking through some of the most down-voted questions on stack overflow, I found many that were asked in a poor manner, although I was surprised to find that almost all ended up with some sort of answer from a kind person, though nowhere near the detail of the branch prediction question. Still, one question stuck out to me, and this question can be found here. The asker has posted a question from their mock exam and is seeking help to answer it. Ultimately, they did get an answer, but they also received a lot of negativity in the comments. The main response that stock out to me was, “The scope of any exam is to test your knowledge of the topic. Asking an “urgent” or “last-minute” question on SO defiles that scope. Plus your question isn’t fit for SO anyway, for many reasons. See here”. Clicking on here sent me to the stack overflow help section, a resource suggested by Raymond in his article. It is imperative to remember that these websites are valuable resources, but the people who answer these questions do so on their own time and do not get paid. This particular question had no benefit to the rest of the community and did not belong on stack overflow in the first place.
A second example of a poorly asked question can be found here. The asker is asking how to get the percentage of a number using javascript, but in the question shows that he or she has no clue how to calculate percentages. This failure to present the question in a smart way, got twenty-five down votes and some ridicule before the question was closed for being off topic. After all, it was a math question in the programming section. The bottom line is that stack overflow is not a place for questions about how to calculate a percentage. There are thousands of resources that one could find on google in a matter of seconds that could answer this question. It’s like Raymond explained, always start with a google search before asking a question.
I have no doubt that I will someday run into a problem that I cannot find the answer to with a search and have to ask a question myself on stack overflow or another similar site. Moreover, I hope to have the knowledge to answer questions myself as a bit of payback for all the help that I have received. What I will not do, is ask questions in a stupid way, because I have too much respect for those who take time out of their day to help others.