In relation to this question:

Optimizing this PHP function

I'm wondering if maybe I wasn't a bit too hard on this particular question. It's a matter of degree with some questions, and some are particularly sticky. Optimization and "improvement" related questions have a tendency to stick out as borderline just by their nature.

How do you know when a question is too off-topic or too localized? I try to ask myself, how would I ask this question in a way that would prove meaningful to later SO users. Sometimes, it's just as productive to edit a question, but when it appears that the OP hasn't tried to narrow the question enough, my initial reaction is to vote to close.

Could the question be improved? Every question could be, I assume. Is it worth it to try and have the OP improve the question? Is it really a judgment call to close a question of this nature? It's perhaps questionable if a question really should be closed just because it's possibly off-topic, instead of "specifically off-topic". In this case, I believed the question was both off-topic and too localized, but the question itself could have been more focused.

SO seems quite a bit more big picture than "I have a problem, please help me" type questions, but we all know they slip through all the time. How do you know if you're legitimately voting to close a question which is at least some kind of gray in this regard?

  • 1
    I was going to write up an answer explaining why it's best to "Vote early, vote often", but I found Cody Gray's excellent explanation (also see the answer he links to from there), and won't try to duplicate or improve on that. I will just say that, IMO, you handled the situation appropriately: voting to close a question which you thought was borderline-inappropriate for SO and commenting on the reasons.
    – jscs
    Nov 20, 2011 at 23:18
  • @JoshCaswell - That's a great link, thank you for sharing. I think the standard itself should be to seek absolute appropriateness, but I wonder at times if the pursuit of perfection in a question may be to waste legitimately reasonable questions, especially when an OP is not a new SO user (which Evert is not). Nov 20, 2011 at 23:31

2 Answers 2


A big problem with code improvement questions is that unless they are asked extremely well and descriptively, they won't be of much use to anyone except the author in the future.

It's a lot better if the question identifies the actual problem, in this case a lot of string matching that's being entered thousands of times. There has to be something in the title and body of the question for other people who would appreciate seeing it to be able to actually find it.

If a question can be sufficiently improved to accomplish this, while inviting objective answers, then I feel that they fall on the on topic side of the fence. Unfortunately, it's difficult to articulate yourself when you don't really understand your problem yet, or even if you're solving the right problem to begin with.

Finally, drastic edits are often required to pull a question like that out, and people might not be comfortable making those kind of edits, since they would border on changing the intent of the question. It really does need to be the question's author that does this, hopefully from constructive advice given in comments.

In this particular case, the question was all but answered in comments, and the question has two re-open votes. I'm pretty sure the OP got what he needed, and if not, he (should) have a much better idea of how to ask the question.

  • You hit on several points, especially the "drastic edits" part, that make it more useful to draw a line than give some rope. I would note that @mario's comment would have made a great answer for this question, given the opportunity. Nov 20, 2011 at 23:28
  • His comment was spot on, but I think a lot of people might have misinterpreted it as 'not an answer to the question', which really does illustrate why these types of questions are very problematic unless worded 'just right'. Any time you find your head hitting a wall repeatedly, you need to wonder if you're solving the right problem; that's something that only experience teaches you.
    – Tim Post
    Nov 20, 2011 at 23:41
  • That's true, but knowing mario's approach, I think his actual answer would have been appropriate, as opposed to a comment. In this case, perhaps the best "answer" available would have been to just do what was being avoided. The fact I have quotes around "answer", though, goes to the heart of why I voted to close in the first place. Nov 20, 2011 at 23:45
  • I think the community made the right call on this. When you see several things wrong that can't easily be fixed, closing appropriately and being as helpful as possible (when warranted) in comments is all you can do.
    – Tim Post
    Nov 20, 2011 at 23:50
  • I feel at least a little responsibility, since I know that a tone is set by a user's initial view of a question. At times, I feel that a "close this question" momentum can build independent of the question itself. I think that rep is meaningful to a degree, and the fact that @ceejayoz was the only significantly rep'd user to vote to close was a little worrisome (and no disrespect to the other close voters). This is one of those questions where it all seems to hang in the abstract in terms of what's appropriate, even considering the fact that four other experienced users agreed. Nov 20, 2011 at 23:59

I don't think that there is "absolute knowledge" in this regard... as you write sometimes it is a grey area and I think that is the reason it usually takes 5(!) votes to close a question...

Which in turn means that at least 4 other people came to a similar conclusion on their own.

In this case I see that the OP didn't improve the question except by asking for a comment from anyone voting that it should be closed - which is legit I think esp. in "grey cases".

In grey cases I first comment and wait a grace period to see whether there is a reaction and/or improvment on the question... if there is neither a satifactory explanation/improvement then I vote to close.

IF the improvment happens after the question is closed there is always the "reopen" vote and/or flagging for moderator attention to explain the situation.

  • 1
    I was thinking the same thing as your last sentence, essentially, "Fix the question and I'll vote to reopen". It can be tricky, though to feel you've got a close (or even a down) vote right. Nov 20, 2011 at 23:04
  • @JaredFarrish I know the feeling but as I said - in grey cases there is first a comment then a grace period then the close vote... so I think that this mitigates the problem as far as possible...
    – Yahia
    Nov 20, 2011 at 23:12

You must log in to answer this question.

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