21

If you go to the Stack Overflow tour you can see, as in the picture below, that it is allowed to ask questions about coding techniques.

Tour snippet

As far as I have been aware though, questions like this are often closed as off-topic/too opinionated.

Closed: Example 1, Example 2, Example 3.
Not Closed: Example 1, Example 2, Example 3

Often posts like these also ask for tools used, which leads into the off-topic side of things.

I feel that Coding techniques would belong on Code Review under the section, "Best practices and design pattern usage".

Could any one clarify what Stack Overflow's view is on coding technique questions? What draws the line between opinionated and off-topic when asking a question about coding technique?

EDIT
As pointed out by Tim Sequine that question like this would be off-topic in Code Review. Perhaps it would be better placed in Programmers.

10
  • 1
    That would be off topic for code review. Maybe programmers would be a better fit though. Commented Jan 30, 2014 at 10:52
  • @TimSeguine I'm not a user so wasn't 100% but it almost feels like they don't belong anywhere? Commented Jan 30, 2014 at 10:53
  • 1
    I think the problem is it is hard to write questions about it that have good answers, as you have already pointed out. I think wherever you ask them they are in danger of closure. Programmers SE is IMO the best fit, but I don't contribute much to that site, so others may have a different opinion. Commented Jan 30, 2014 at 10:55
  • Oh, software development tools are off-topic too on SO? No?
    – devnull
    Commented Jan 30, 2014 at 11:26
  • The closed questions aren't closed because they're on coding techniques - they're closed because they're overly broad. Commented Jan 30, 2014 at 14:00
  • 6
    They're closed because someone can. I think this question is brilliant in that it gives concrete evidence ("Coding techniques" screen shot) that questions are being closed when they should not be. Many of the questions I am interested in don't fit within any community's restrictive ad hoc rules. Lighten up and improve the site.
    – user985690
    Commented Apr 21, 2014 at 16:17
  • I think the answer is to get a little more rep and then go through the close queues and vote against closing in cases like that. Until then, leave comments about why it's stupid that the question was closed.
    – Warren Dew
    Commented Apr 23, 2014 at 5:36
  • 3
    I think questions can be overly broad to some users, but when I look at some questions labelled as such I think "Oh, I know just how to answer that!"... but then I don't because I assume the question will just be flagged and closed anyways.
    – Matt K
    Commented May 29, 2014 at 20:53
  • I agree that there should at least be some forum more accessible than chat for more general questions that don't abide by the strict format here. This example is one that I answered that I feel is a reasonable question, given somebody has no pre-existing knowledge of an area, which could be useful to others too. I feel like this format and community response could deter people from using SO. Commented May 28, 2016 at 6:44
  • Stack overflow is actively hostile to questions about techniques. Well formed questions asking about debugging techniques in specific scenarios where the problem is unclear to the developer are closed because they "don't contain code examples". I guess it fits into the fact that Stack Overflow is hostile to newer programmers, even when they ask reasonable questions. Moderators seek to close questions to get their rocks off mostly. Commented Oct 23, 2021 at 1:03

1 Answer 1

4

There is a very large difference between a list of techniques followed by "so what do you think?" or "can I have some feedback" versus a very specific aspect followed by "why does that happen?".

So far as the question asks something with a unique answer on technique for the most part it should be well received. These types of questions are very common on Stack Overflow, and in my opinion are relevant as when asked properly they can expose useful information in a concise manner.

In a similar situation to coding techniques, asking why decisions were made in language implementation has the same pitfalls. Eric Lippert does a great job of explaining a summary of do's and don'ts there that I think applies to coding technique to some degree as well.

In general, questions asking about technique aren't problematic in and of themselves, they are problematic when they fall into common pitfalls of questions in general which include being vague, broad, opinionated, or lacking a good description of "here is what I know, here is what I don't know".

You must log in to answer this question.

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