Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 157 Stack Exchange communities.

What is meta?
Here's how it works:
  1. Any Stack Exchange user can ask a question
  2. The community provides support, votes on ideas, and reports bugs
  3. Your voice helps shape the way Stack Exchange operates

I just saw a couple of questions that basically ask for an answer in any number of specific languages:

Since there is (by definition) no one right answer, are these still considered on-topic for SO?

What should be done with these - migrate to programmers? Close with extreme prejudice?


For clarification - I do not mean real world uses questions (problem involving several languages in a valid scenario - say javascript, C# and SQL in a web scenario), or to do with how different languages interoperate (say C# and VB.NET assemblies on the .NET platform).

share|improve this question
Oh, good point! It sort of invites "discussion" of which language would be better to accomplish the goal, too. (the first of your examples, especially). Of course, you aren't referring to questions that are legitimately concerning multiple languages for some sort of interop scenario. – Andrew Barber Jan 6 '12 at 19:51
I think we still allow questions where multiple answers would be valid. I lurk in the SQL tags mostly, and in most things SQL there are about 10 different ways to do everything. – JNK Jan 6 '12 at 19:52
@JNK'sMetAccount - Yes, but they are all SQL. What would you do with a question asking for answers in either SQL or D or ISBL (or whatever relational query language)? – Oded Jan 6 '12 at 19:56
I'd give them a SQL answer since that's what I know :) – JNK Jan 6 '12 at 19:58
Since they asked for it in SQL or D or ISBL, I would answer in whichever of those 3 languages I felt most comfortable with. – cdeszaq Jan 6 '12 at 20:06
Test comment. Will delete. – GSerg Jan 6 '12 at 20:55
up vote 4 down vote accepted

To me, there would still be a correct answer for those questions you listed. An answer could be in any of the indicated languages. The OP in those cases isn't looking for an answer in each of the languages. While this could easily incite discussion on the merits of one solution over another due to the language used, that isn't really what the OP is looking for. Discussion about the merits of each solution based on language are rather off-topic for that question, since it isn't what the OP is looking for.

If the OP is looking for a language comparison for a given algorithm, then that would be a different sort of question. In that case, I would expect the question to include a set of implementations and then be asking for pro's / con's of each.

The case of looking for an answer in each language should be broken out into different questions, one for each language. Combining them into 1 question doesn't do any good and makes the information less accessible, since it's all lumped together.

The difference ultimately comes down to OR vs. AND. If the OP is looking for a solution in any language s(he) is familiar with, that's fine, but if the OP wants an answer for each language, then split up the question.

share|improve this answer

Questions with possible answers in multiple different languages are a difficult fit for the SO Q&A platform. I say close with a vengeance unless there is a clear real-world reason for the choice of languages listed (like in web development, JavaScript being the possible client side solution, C# the possible server side one.) Of course, questions about interoperability between two specific languages are also fine.

But most (not all, but most) multi-language questions are either

  • questions where the OP is asking without a real-life use case - often invitations to discussion, and closeworthy

  • questions where the OP doesn't know what they're talking about

  • Interview questions with arbitrarily combined languages (like the second one you show)

  • X platform vs. y platform questions

all clear reasons to close.

share|improve this answer
You can also have JVM-based solutions that can have lots of different languages all playing together. Groovy and Java have nearly seamless interoperation, for example. – cdeszaq Jan 6 '12 at 20:05
@cdeszaq yeah, that would fall under the "clear real-world reason" category and is perfectly fine. – Pëkka Jan 6 '12 at 20:06
@cdeszaq - The same can be said about .NET languages. That's not the thrust of my question though. – Oded Jan 6 '12 at 20:06
Another instance that fits the "real world reason" is SQL vs. HQL. With Hibernate, you can use either one fairly easily, and converting from one to the other isn't particularly hard either. – cdeszaq Jan 6 '12 at 20:08

I would think that most, if not all, questions about polyglots would be puzzles or fun diversions (e.g. requests to generate polyglots that do X or use at least N languages) rather than serious code intended for production use. As such, I think they would fit nicely at Programming Puzzles & Code Golf SE instead of SO. That said, I don't use that site myself, and there is a caveat: the FAQ there says that all questions must have

An objective primary winning criterion, so that it is possible to indisputably decide which entry should win.

However, a question about a single specific code issue within a polyglot could fit on SO. For example, something like

I took this existing polyglot [code here] and made the following modification [more code here] and now it doesn't work in Ruby anymore. Why not?

might be okay.

share|improve this answer
These questions aren't about polyglots at all, I'm not sure why the OP used that word in the title. They're just questions where the answer can be in a number of different languages – Michael Mrozek Jan 6 '12 at 20:21
Yeah, but he did, and someone else answered the body, so I answered the title. – Pops Jan 6 '12 at 20:26
@MichaelMrozek - Questions that have to do with multiple languages then. I was using the term in its non CS meaning. – Oded Jan 6 '12 at 20:42

You must log in to answer this question.

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