Is this a smart question?

07 Sep 2017

As you go through life, you learn to ask questions, but most of the time, you’ll end up with more questions rather than the answer. Then there’s the case where there are an enormous amount of answers, but none fixes your problem specifically. This is the problem that software engineers will always run into as there are infinite possibilities to implementing or solving a problem. When asking smart and insightful questions, you will get a technical and concise answer. Intelligent software engineers are always on the lookout for those good, thought-provoking questions and you get their attention by asking questions the correct way.

I committed the wrong files into Git. I haven't pushed the commit to the server yet. How can I undo those commits?

This is an example of a poorly written question. The first thing you notice is that the person asking the question clearly did not do their research before posting it to the online forum. This type of problem will most likely be answered on the GitHub website. Also the question is very vague. This is proven by the enormous amount of solutions the question got, which almost all of them are different. The question should be specific and describe exactly what occurred, so it paves a path for the correct answer. There are no guidelines to asking questions, but it is important to choose the right forum, use meaningful subject headers, be informative and precise, to get the answers you want.

I'm trying to find a way to scan my entire Linux system for all files containing a specific string of text. Just to clarify, I'm looking for text within the file, not in the file name. When I was looking up how to do this, I came across this solution twice:
find / -type f -exec grep -H 'text-to-find-here' {} \;
However, it doesn't work. It seems to display every single file in the system. Is this close to the proper way to do it? If not, how should I? This ability to find text strings in files would be extraordinarily useful for some programming projects I'm doing

Here is an example of a “smart question”. First of all, the person does a nice job stating specifically what the problem is. Additionally, the user shows some understanding of the solution and has tried a possible solution, but was unsuccessful. These types of questions will yield concise and quality answers. As software engineers, asking “smart questions” will give way to intelligent answers, which then leads to better knowledge of our field. If we want the answers that will give us a better understanding of our problem, we have to ask the question the right way, the smart way.