This question was closed as unclear:


The question has a well-defined input and output, and the question title made the goal clear: shorten it as much as possible. It was closed as unclear. That user may come back and attempt to "clarify" the question, and then finally our hand will be forced, and we'll have to tell him the real reason why it was closed:

This question appears to be off topic because it is primarily code that the community has been requested to shorten or improve in some way.

If this community does not actively golf or improve other people's code, just be straightforward and say that (in a nice way). I propose that we use the wording above, but I'm open to suggestions.

Here's a more verbose, alternative wording. I think it's too long, but it reflects the point that I would actually want to get across to the offending user.

This question appears to be off topic because it is primarily code that the community has been requested to shorten or improve in some way. If you need feedback, try posting a challenge, and then posting your code, shortened or improved as much as possible, as an answer to that challenge.

  • 3
    \$\begingroup\$ Personally, I agree with Martin's comment. It would be helpful to know what's supposed to be happening before I dive into the code. A synopsis at the top would go a long way toward reopening, IMO. Right now it's the equivalent of a 'gimme-the-codez' dump at SO. \$\endgroup\$ – Geobits Oct 27 '14 at 17:40
  • 1
    \$\begingroup\$ The real problem isn't that the asker has code. The real problem is that the asker didn't provide a spec. "How do I golf X" is fine if you tell us what X does. \$\endgroup\$ – John Dvorak Oct 27 '14 at 17:45
  • 2
    \$\begingroup\$ The real reason that it was closed is that it's not clear what the question is. Firstly, code is not a spec: without an actual spec no-one knows which optimisations are permitted. Looking at that massive chunk of code and the output, I would be inclined the throw the lot away and replace it with hard-coded output. Secondly, "How" is ambiguous: is he asking for principles or for us to actually do the work? Thirdly, where does "make dict for non emty lists" fit into this? \$\endgroup\$ – Peter Taylor Oct 27 '14 at 17:46
  • \$\begingroup\$ @PeterTaylor When a compiler optimizes code, does it need an English description of what it does in order to determine which optimizations are permitted? No. The only rule is that the behavior must remain the same. My college professor had another name for it, but the Internet calls this the as-if rule. Code can serve as a spec, and a perfectly unambiguous one at that. \$\endgroup\$ – Rainbolt Oct 27 '14 at 18:58
  • \$\begingroup\$ @Geobits What's your point? I'm not here to discuss whether hard-coding output is a good or bad thing, and I'm pretty sure there are other meta posts on that subject. Please stay on topic. \$\endgroup\$ – Rainbolt Oct 27 '14 at 20:25
  • 1
    \$\begingroup\$ To be clear, I do agree that it could be a good new close reason, provided we actually need it on a more regular basis (as Peter answered below). However, if you want the change to be made, you have to offer good evidence that it's needed (or at least beneficial). I'm saying your chosen evidence is not good. At the very least, it's disputable, and only one case. \$\endgroup\$ – Geobits Oct 27 '14 at 21:11
  • \$\begingroup\$ @Geobits In that case, the question is a kolmogorov, the ideal answer is hard-coded, and the spec is clear. It's almost as though you wanted to tell me that it is a hard-coded answer and then try to get me to argue that it isn't. \$\endgroup\$ – Rainbolt Oct 27 '14 at 21:24
  • \$\begingroup\$ @Geobits I wholeheartedly agree that the author's intentions are what is unclear, and not the challenge itself. It didn't me several comments to establish that the challenge was a Kolmogorov, so speak for yourself. The moment you mentioned it, I went and read the Python code and concluded "This is a Kolmogorov." Please refrain from including me in your confusion. \$\endgroup\$ – Rainbolt Oct 27 '14 at 22:41
  • \$\begingroup\$ @Geobits You have now stated that if it isn't a Kolmogorov, then the spec is unclear, and if it is a Kolmogorov, then the spec is unclear. Your proof is the fact that we are here arguing about it, which isn't actually proof of anything. It seems like your only argument is the very act of arguing itself. Thank you for polluting the comments section of my post. \$\endgroup\$ – Rainbolt Oct 28 '14 at 13:36

The five per-site custom close reasons are for handling common problems. Until we're closing a question a week for being "Do my golfing for me" questions we don't need to change the site config.

  • \$\begingroup\$ This answer implies that we don't already get a question per week asking this community to golf, speedup, obfuscate, or otherwise transform their code. I can't really prove that we do, because those questions tend to disappear shortly after they arrive. \$\endgroup\$ – Rainbolt Oct 27 '14 at 18:30
  • \$\begingroup\$ If you note down the question IDs when you see new ones coming in and update this with stats then you will have a more persuasive case. \$\endgroup\$ – Peter Taylor Oct 27 '14 at 19:12
  • 2
    \$\begingroup\$ Well, you dismissed my case with a not so persuasive case of your own. I'm not going to put forth a lot of effort to put together a case that I can already tell nobody will care about. That would be a waste of my time. I will put forth a lot of effort when the I feel like the community is ready to accept the results. I think it's just a bit extreme to say "Monitor incoming questions for months or you have no case." \$\endgroup\$ – Rainbolt Oct 27 '14 at 19:17

You must log in to answer this question.

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