Reflects on Smart Questions

06 Sep 2018

Smart question

Smart Question

The reason why this is a smart question is because the poster attempts to explain everything that they are trying to do. For instance, they provide the JSON that they are working on:

[
{
  "LAST":"Betsy",
  "FIRST":"Jackson",
  "DEPT":"Customer Service",
  "SUBDEPT":"Tech Support",
  "JOINED":"02/94",
  "TITLE":"Technical Customer Service Representative",
  "RESIDENCE":"Someplace",
  "HOBBIES":"Reading, Walking, Sleeping"
},
{
  "LAST":"Sally",
  "FIRST":"Smith",
  "DEPT":"Customer Service",
  "SUBDEPT":"Installation Customer Service Representative",
  "JOINED":"01/04",
  "TITLE":"Technical Customer Service Representative",
  "RESIDENCE":"Someplace",
  "HOBBIES":"Reading, Walking, Sleeping"
},
]

Along with the problem they are trying to solve by going into details. Where the problem is:

“I’m trying to build an application where users can click on the name of an employee and see a refresh of results where every employee in that employee’s department is shown, organized by the sub-departments, and scrolled-down to the given employee”

$.each(data, function(i, employee) { 
    if (employee.DEPT == dept) {
    var employeetext = '<span class="name">'
     + employee.FIRST+' '+ employee.LAST+'</span>',
     employee.JOINED, 
     employee.TITLE, 
     employee.RESIDENCE, 
     '...', 
     employee.HOBBIES;  

        $('#employees').append('<div class="employee_block"><img src="" width="85" height="113">' + employeetext + '.</div>');  

        results.push(employee); 
}
})

The poster’s articulation of the problem goes in-depth and the resulting reply from another poster demonstrated how asking a question by providing details is important to solving the problem and gaining insight.

Not so smart question

Not so smart question

The reason why this is a not so smart question is that it’s a duplicate question that has been answered multiple times before. Additionally, the question itself does not provide any details to the problem with sorting a JSON list. In the body of the post the poster did provide his code that they are having issues with. However, there is nothing more to it other than the code block that they posted.

Why we need to ask smart question

Asking smart question allows other posters to answer questions without having to ask too many other questions and deliver a better explanation to the questions asked. A poorly asked questions will often times be vague and provides no additional details to help other posters answer the question. Which would require other posters to ask more questions to find the real problem that exists. If they don’t pry into vague questions they will also often go unanswered or ignored on Stackoverflow.