15
\$\begingroup\$

Let's say I have a challenge that is difficult. Indeed, people may believe it to be impossible, since it is somewhat obscure. Should I provide a completely non-golfed answer, sort of as a hint, to show its possible. It makes sense to not golf 1) it is easy to understand (which would be the point of such an answer) and 2) it does not give away any golfing tips for that challenge (and also will not prevent them from not doing something so as to not copy me).

\$\endgroup\$
  • 3
    \$\begingroup\$ A challenge you wrote, or someone else's? \$\endgroup\$ – feersum Nov 1 '15 at 4:53
  • 7
    \$\begingroup\$ You mean a reference implementation? People do that - a solution written that works, but isn't code-golfed. It demonstrates the specs you put out, but not the code-golfing aspects. \$\endgroup\$ – Mama Fun Roll Nov 1 '15 at 4:56
  • \$\begingroup\$ @molarmanful yeah \$\endgroup\$ – PyRulez Nov 1 '15 at 11:28
  • 8
    \$\begingroup\$ will not prevent them from not doing something so as to not copy me Error: too many negations. Unable to parse. \$\endgroup\$ – Dan Henderson Nov 2 '15 at 19:32
23
\$\begingroup\$

Yes, but don't make it an answer. If you have a reference implementation whose only purpose is to show what is being asked, but which doesn't respect the winning criterion at all, it's not an answer by our standards. Quoting the help centre:

All solutions to challenges should:

  • Correctly implement the required specification.
  • Be a serious contender for the winning criteria in use. For example, an entry to a code golf contest needs to be golfed, and an entry to a speed contest should make some attempt to be fast.

If it doesn't do that, it's not an entry to the challenge, so it shouldn't be an answer. Just include it in the challenge itself at the bottom.

Of course it's also completely fine to participate in your own challenge and submit a golfed version of your reference implementation. Just don't encourage others to submit answer along the lines of "I couldn't be bothered to golf this, but hey I solved it!".

\$\endgroup\$

You must log in to answer this question.

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