13
\$\begingroup\$

This question is meant as a general question, but it is also specifically about this specific question:
https://codereview.stackexchange.com/questions/39228/original-factorial-method-in-java/

It is known that only your own written code are on-topic on this site. However, as programming sometimes is to take some pieces of code from different places and put it together, I am wondering: What does it take to make some code that you have found somewhere "your own"?

As an example, if the specific question above would change the identifier names (parameters and method name), use a different indenting, another kind of exception thrown, etc. Could then the code be called "my own"? (and the question possibly re-opened) Because there is really no other structural different way of doing what is done in that code (except following the guidelines from my answer of course).

\$\endgroup\$
16
\$\begingroup\$

What does it take to make code your own?

Good faith.

While I think the potential licensing issue reason makes sense, I also believe that the true reason behind this close reason is because of the spirit of Code Review, which is to post the code you've written and get it peer reviewed.

Sure, one can game that rule, grab code online, twist it a little (or not), include it in their post as part of their own code, or even as the entire post, and pretend it's theirs. Who cares at that point?

By clicking Post Your Question on CR, you're saying "I wrote this code, does it make my ass look fat?". If you didn't write it, well, you're being dishonest, and you stink and I don't want to be your friend.

However if you didn't write it, and acknowledge it, and it's all there is to review, your question should get closed. If you didn't write it, and acknowledge it, and it's only, say, a single method in a 300-liner class that you're posting, you're forgiven and not only you don't stink, you're honest enough to say "this part here, I grabbed from [SO link] and it works well, feel free to review it along with the rest, or skip it.", and I like you and I'll even give you an upvote.


Do we still need to close questions that explicitly aren't about the OP's own code then? Absolutely!

Do we need to be the "code ownership police" and hunt down liars? I don't think so.


Specifically about the question you've linked, I think the OP asked in good faith, but didn't read our [help/on-topic] page, and it could have been a much better fit for Programmers.SE.

\$\endgroup\$

You must log in to answer this question.

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