Smart Questions Yield Smart Answers

25 Jan 2024

The Importance of Asking Questions

When developing software, it is inevitable to run into coding issues. Asking questions on forums such as StackOverflow is a great way to receive input and feedback that will help get you unstuck. Not only this, but asking questions can benefit other people as well. Personally, when I encounter problems with my own code, one of the first things I do is type the issue I am having into Google. While documentation exists for this purpose, StackOverflow can sometimes be a good safety net for more complex problems. If you are lucky enough, you may encounter a solution given to someone else who experiences the same or similar issue in the past.

There are many benefits to asking such questions. However, some questions are more effective than others. Asking broad questions can yield broad answers that do not give you the information you need to solve the task at hand. Asking “help me fix my code” is an example of a very ineffective question. On the other hand, being specific in requests will help others help you.

Attached are some examples of both “smart” and “not smart” questions.

One Smart Question

https://stackoverflow.com/questions/45225076/incorrect-line-numbers-sourcemaps-webpack-2-typescript

This questioner has clearly done some research to fix the problem before posting it to the forum. They provide a list of ways in which they have already attempted to correct the issue along with the (unwanted) results. Furthermore, they provide numerous snippets of their Typescript code and highlight which portions of it in which they are seeing the “wrong line number”. This user has demonstrated a clear effort to attempt to solve their problem and has gone through the steps to create a smart question.

One Not-So-Smart Question

https://stackoverflow.com/questions/32255666/interruptedexception-when-debugging-android-app

It is also important to be aware of not smart questions disguised as smart questions. For instance, a question such as this one may cover a majority of our criteria for a smart question. In this post, the questioner provides a snippet of the exception that they receive when the app they are debugging crashes. They also state two scenarios in which the app crashes (as seen in the screenshot). While this might seem to be a smart question due to its conciseness and with the information it provides, it violates a few of our smart criteria. Namely:

Describe the research you did to try and understand the problem before you asked the question. Describe the diagnostic steps you took to try and pin down the problem yourself before you asked the question. Describe any possibly relevant recent changes in your computer or software configuration. If at all possible, provide a way to reproduce the problem in a controlled environment.

Final Thoughts

There is something to be said for both of these questions. However, examining them from the perspective of smart criteria highlights some major differences between the two. Overall, the first question is much “smart”-er than the second, and therefore would generally yield better results. It helps to be smart.