20

Specifically this question.

I saw the question and it looked pretty simple so I decided to answer it. However, I do think it's important to encourage and ask people what they have tried first. It was later that someone pointed out that his other questions have been simply asking for help without trying.

I think for this situation I am leaving my answer (I just tried to make my answer clear so they can learn from it and I posted a note about showing what you have tried) but for future reference, if its pointed out that an asker is simply not trying for any of his questions, should I delete my answer? I want to assume good faith but also wanted to clarify because looking at a lot of other questions regarding what have you tried I couldn't find a stance on the issue exactly.

EDIT: Unfortunately (or perhaps fortunately? I guess it depends what perspective) the question has been deleted so for those stumbling upon this I'll just briefly summarize the question -- If I recall correctly it was about how to iterate over a JSON object which had keys that pointed to arrays that had more JSON objects. He wanted to know how to manipulate the JSON objects and add a property to them.

11
  • 7
    This is our fault. That question was not closed quickly enough, so you have been able to answer it. I just cast the first vote. By the way, how did you guess the right number of objects to create for each product? It is not clear at all to me. Commented Feb 18, 2016 at 19:17
  • 3
    @FrédéricHamidi yeah well after answering, I noticed the number of objects was off which is why I wrote "Hope I understand this right". In all respects I think I jumped on the answer too soon and ideally I should have clarified. I also have the power to vote to close so I think that is my fault as well :/
    – aug
    Commented Feb 18, 2016 at 19:26
  • 6
    Indeed you can. I was thinking it required 10K instead of 3K for some reason. So yes, you can include yourself in "our fault" ;) Commented Feb 18, 2016 at 19:28
  • 6
    @FrédéricHamidi, aug - I don't necessarily disagree with you guys, but I also look at this site as a knowledge base, as well as, a question and answer venue. I too have struggled with why should I answer a question when the OP doesn't seem to be trying, but I wonder how many deserving individuals down the road I'm depriving of an answer. Just something to consider.
    – Kevin
    Commented Feb 18, 2016 at 21:04
  • 2
    @Kevin, heh. You said forum. Commented Feb 18, 2016 at 21:05
  • @FrédéricHamidi That better?
    – Kevin
    Commented Feb 18, 2016 at 21:07
  • @Kevin, yup. Plain Q/A site also works. Commented Feb 18, 2016 at 21:08
  • 5
    I don't really get the whole attitude of "you gotta work for it." If there's enough information provided to get an answer, and someone willing to answer it even though the asker was lazy, everyone else can mind their own business, right?
    – erickson
    Commented Feb 18, 2016 at 21:35
  • 14
    I'm firmly in the "leave the answer" camp. When I use google to figure out how to do something for the first (or second or umpteenth time) answers on stack overflow typically end up being my best resource, particularly because I can use the examples people like you provide to get clarity that straight docs might obscure. TL;DR, the information is more wide reaching than just the person that asked the question.
    – JackChance
    Commented Feb 18, 2016 at 21:50
  • 1
    @erickson it's everyone's business because answering questions posted by people that put forth no effort at all a) encourages more people to avoid doing their own work first and b) degrades the quality of stack overflow. That said, I'm not judging either deleting the answer nor leaving it present; that's up to each individual's decision for their own answers.
    – mah
    Commented Feb 19, 2016 at 22:27
  • You have just stumble across the rep point trouble in SO, you got a 100 points, so obviously SO is saying thanks and probably you should be happy... However is it good for the SO framework in the long run... I tend to agree with cimmanon answers, but then again SO can just "pack the dirty" (in this case refeering to question) with some fancy google algorithm and everybody is happy Commented Feb 19, 2016 at 22:46

2 Answers 2

20

In general you should not base what to do with answer based on amount of effort put by person asking the question.

For particular question - you should not have answered, but definitely should not remove answer unless you find it invalid (i.e. if OP clarifies question to be different from your answer - not the case as your post is accepted).

It is generally frowned upon to answer questions that request code without any demonstrated effort. Such answers

  • encourage bad questions,
  • invite "don't do this" downvotes* to one who provided the answer.
  • lock negative reputation for person asking bad question (clearly jerk behavior which I totally understand also not formally support)

*Note that as Servy pointed out it is often hard to provide good concrete answer to such question and hence get well deserved downvotes for unclear/incomplete/unrelated answer.

10
  • 13
    People seem to assume that answers to bad questions get downvoted because the question is bad. Bad questions typically make it impossible, or at least extremely hard, for the question to actually get a good answer. They also are much more likely to attract low quality answers. Answers to bad questions get downvotes because the answers are almost always bad. The answers are often bad because the question doesn't allow them to be good.
    – Servy
    Commented Feb 18, 2016 at 22:04
  • 1
    @Servy indeed many votes on such answers are valid, but I was talking about particular type of downvotes (I've updated post to clarify) Commented Feb 18, 2016 at 22:11
  • I'd second that @Servy - I've seen a question recently where the OP asked how to make an Excel file in a non-sensical manner. An answerer gave a decent suggestion about how to make Excel files in general, but it could only ever accidentally answer the OPs question because the initial question made no sense.
    – Dan Field
    Commented Feb 18, 2016 at 22:13
  • @AlexeiLevenkov And I'm saying that that particular type of downvote is mostly a myth. People assume that bad answers are downvoted because the question is bad, rather than because the answer is bad, even if the voter really feels that the answer isn't useful.
    – Servy
    Commented Feb 18, 2016 at 22:14
  • @Servy I'm perfectly fine with it being completely imagined practice if it discourages bad answers :) Commented Feb 18, 2016 at 22:16
  • I have seen several no-attempt questions in the last few days where the answer was decent yet was downvoted with a comment suggesting not to answer bad questions. Not entirely a myth.
    – Eric J.
    Commented Feb 18, 2016 at 22:16
  • 2
    @EricJ. That assumes that a code only answer to a requirement dump question is useful. I would reject that premise. Just because an answer is technically correct doesn't mean that it's actually useful.
    – Servy
    Commented Feb 18, 2016 at 22:22
  • Not commenting on whether it is useful, only that it happens.
    – Eric J.
    Commented Feb 18, 2016 at 22:25
  • Thanks for the answer :) and just wanted to say you make a really good point @Servy
    – aug
    Commented Feb 20, 2016 at 4:36
  • @EricJ. You stated that the answer was being downvote despite being not a bad answer, which would mean it would need to be useful. If it's not useful, then it's not a good answer, downvoting it would be appropriate.
    – Servy
    Commented Feb 20, 2016 at 4:58
9

If you felt the question was unclear, why did you post an answer to it? By answering, you're potentially preventing the Roomba from deleting off-topic questions.

One of the reasons we prefer to have users show what they've tried is so that we can avoid replicating steps that obviously don't work.

For this particular question, it may have been appropriate to close it as a duplicate of a question that asks "How do I iterate over a JavaScript object's properties" or "How do I add a property to a JavaScript object". There is little to no value in answering duplicate questions, especially of popular, well-established questions that future users are more likely to find than the one you've just answered.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .