I've tried to contribute to the community by publishing a solution to a problem.
I thought it is allowed and welcome on SE. But then I get many downvotes and that's it. What did I do wrong?
I've tried to contribute to the community by publishing a solution to a problem.
I thought it is allowed and welcome on SE. But then I get many downvotes and that's it. What did I do wrong?
Questions asked on this site are expected to be of high quality. The fact that you answered it yourself is entirely irrelevant; questions will be evaluated in isolation. The question should be a good question even if you don't answer it yourself. A two sentence rough description of a project to be solved is a terrible question. What would you do if you saw someone post a question like that? Hopefully you'd downvote it, as was done here.
The answer is not particularly great either. It's just a code dump. There are no explanations or details.
:P
You can certainly self answer your own question. In fact you are encouraged to do so. However, the question and the answer must still adhere to the standards here. Meaning the question must be complete and thorough, describing the issue you are having and what you've attempted to overcome it. And the answer must be complete explaining the solution along with providing relevant code or links to docs.
For that reason, self answering questions are much harder than a normal question because you already have the answer to it so wording a question is tricky. In general, most self answered questions on SO don't fare well for this very reason.
As @me how points out in the comments there is even a badge for doing this. So if you are looking for some examples of people that have done it right that would be a great place to start.
I'd hazard a guess at:
I realize I may be putting a small chunk of hard earned reputation at risk by exposing this as an example but I have just recently asked and answered my own question.
I randomly ran into a problem putting an ampersand in a header in Excel. I searched Stack Overflow, and Google. I have found an answer on an off-site resource but since I couldn't find a matching question/answer like that on SO I decided to post a question and answer it myself so any future people who run into the same problem can easily find a reference to a solution.
Note: I really have tried to follow guidelines for asking a good question - simply, not to get the question closed within the first 10 views. I tried to at least describe what I was doing and what the problem was. I though I made it clear what the problem was...
Posted an answer to it within minutes... As it turned out in the end I have got two votes on my question; a downvote and an upvote and (surprisingly) 3 uvotes on the answer.
I have used my own as an example so hopefully no-other SO member will experience a random waterfall of up/downvotes.
What my advice is for you in the future:
Research Stack Overflow, make sure the question you are about to ask and answer yourself has not been asked before.
Form your question according to how-to-ask guidelines just try to make sure it's not a sentence long question/answer.
Any content that remains on SO is considered useful and helpful to future visitors, make sure you make it a useful resource for any future reader. Explain your specific problem in a question and explain well why your answer is the best
Just to add on top of this all - I have previously asked questions which I happened to answer some time later - I have had no intention of answering while posting to it's perfectly fine to do that. You even get a badge if your answer to own question receives 3 votes :)
It seems you wrote a long-winded (code-wise) and stylistically suboptimal solution without explaining your approach. You might want to post your code on codereview.stackexchange.com to get feedback about the style, or look at the comments on SO.
Your question in particular needed to show work. Now that you've shown it, you're allowed to post it as an answer and check that you were able to answer it yourself.
:/
:/
See On Interviewing Programmers: "I just can't muster any enthusiasm for completely random arbitrary problems in the face of so many actual problems." -- Jeff Atwood.:/
. From help center: questions must generally cover "practical, answerable problems that are unique to software development". In my opinion, the question fails the practical criterion. But that's just my take on it, maybe other people will disagree.