Sometimes we get questions from a first-time contributor asking for help golfing a particular piece of code that they wrote. Often these question don't fare so well. Can we do anything here?

There's many ways for these questions to go wrong. A benign one is for answerers to treat it as a standard code golf challenge. Except, it's limited to a single language and often unclear on what the task is exactly, so it would be closed as a normal challenge. The answers are often just "X bytes" and some golfed code without explanation, which isn't really giving tips for the asker.

Another failure mode is the that asker says answers won't work for them because of some unmentioned rule like that the code has to fit in one line or run within two seconds. We have pretty liberal rules about I/O and things that can lead to improvements that the asker can't use. Conversely, they might have allowances we don't know about like free imports.

Finally, a number of these questions seem to just be attempts to cheat at an ongoing outside competition, which leaves a bad taste in my mouth.

I think questions like this are important to handle well. We have users coming in with an existing interest in golfing and drive to improve, and they might stay as long-time productive contributors. How can we make these types of questions work out better?

  • \$\begingroup\$ It may be good to add either information from the answers here, or a link to this question, in the tips tag description. While new users probably won't read it, I think it will help the users of this site more easily solve the problem of guessing if the poster wants to post a challenge or if they want to ask for help. \$\endgroup\$ Mar 2 '20 at 20:17
  • \$\begingroup\$ @FryAmTheEggman I made a pass at editing the tag. Let me know if you have other suggestions. \$\endgroup\$
    – xnor
    Mar 25 '20 at 8:11
  • \$\begingroup\$ I think what you added was good; I made a small edit to include that the code has to already be working. \$\endgroup\$ Mar 25 '20 at 13:43

Enforce standards for these questions

I think a lot of the problem is that golf-this-for-me tips questions aren't held to the site's usual standards of clarity, completeness, and objectiveness. I know these can be hard for new askers to get a handle on, but we already require the same for challenges they'd post. Sandboxing should be strongly encouraged here too.

Basically, I'm saying these questions should be closed if our close reasons apply.

I propose these requirements for clarity:

  • The task being solved must be specified to the level we expect of challenges. A reference implementation is not sufficient.
  • Any additional requirements should be noted, such as language, version, and run-time.
  • Any deviations from site standards in scoring or I/O format should be noted.
  • All relevant information must be in the question body, not behind a link or in comments.

Additionally, these questions need to meet the standards of focus, research effort, and attribution that are expected of Q&A on the network, in particular for "help me with this code" questions seen on SO.

  • Simply dumping code and saying "How can this be shorter?" is not acceptable. The poster needs to state things they've tried or point out specific parts they think could be improved.
  • The source of the challenge should be credited, with a link if possible. If applicable, the asker should explain why it's OK for them to post the challenge and ask for help with it.
  • \$\begingroup\$ I think it would also be beneficial to ask such questions to include what else they have tried. That way we can avoid repeating work, etc. they have already tried. \$\endgroup\$ Mar 2 '20 at 20:21

Regard Them As we Would Pop-Cons

Looking at the most recent questions, it's clear that questions asking for golfing advice can vary in their successfulness. Of the 13 recent questions asking for advice, only 3 of them were closed and 1 of them was closed as a duplicate. The other 9 have an average vote count of around 5.7, with the highest vote count being 11 and the lowest being 3.

This kinda reminds me of the whole entire popularity contest problem that we as a CGCC community have always struggled to fix. Done well, the challenge is successful. Done not so well, the challenge gets pretty-much insta-closed and disregarded.

In the same way, golfing advice questions done well are received well by the community, but done not so well get downvoted into oblivion (sure, there were also other issues like their community involvement, but even the accepted answer was flagged as being "not an answer, but a comment").

The Solution

My idea is quite simple really. Somewhere, like the tag wiki for , we have a message like so:

Golfing advice questions, while allowed, are heavily disfavored by site culture. You're likely better off reworking your question to be a challenge with an objective winning criteria.

Quote appropriated from @xnor's answer to "Things to avoid when writing challenges" regarding pop-cons.

In summary: they are on-topic for the site, but need to be written and presented well.

Alternatively, we could promote and push for the usage of the tag, which seems to be recently created (I think). Although it is a tag-synonym at this point, we could (probably) change it into a usable tag.

  • \$\begingroup\$ Maybe I'm taking the quote from my answer about pop-cons too literally here, but would "reworking the challenge" mean making it a non-tips code golf question? Or still a tips question but written better? \$\endgroup\$
    – xnor
    Feb 28 '20 at 23:23
  • 2
    \$\begingroup\$ I don't think that tips questions are hard to do well in the same way as pop-cons. I think that if we offer the right tools golfing tips can be made good easily. \$\endgroup\$
    – Wheat Wizard Mod
    Feb 29 '20 at 14:25
  • \$\begingroup\$ Upvote just because it's Lyxal. \$\endgroup\$
    – null
    Aug 4 '20 at 11:29

You must log in to answer this question.

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