Morals over copying code?

What is everyone’s opinions of copying others code to assist in their own coding? I personally only take small segments, and only if the code is from free tutorials.


I don’t copy large chunks of code, but only small ones, and then modify them to suit my style of writing code (for example, I replace single quotes with double quotes).

I often have a situation when the code I wrote returns an error I don’t understand and I have to search the Internet for a solution to my problem, and when I find it, I have to partially copy the code.

I don’t use paid sources, instead I can study documentation and blogs for a long time, because I don’t have money to pay.


Well, all public Repls are under the MIT license which means you can legally copy them without giving credit. Morally though, I think as long as you’re not like copying just to be a copycat but genuinely learning and making something new that it’s fine. I learned HTML/CSS by taking apart code that others had made and restructuring it. That’s also where I got my base knowledge in JS. And then if you come to Ask looking for help 75% of the time somebody will provide a fully functional code designed just for your project and there might not be a better way so why not use it?

1 Like

i rember i forked a repl game once and modified it i neaver really took credits off from the og creator but they got mad and said they would sue me if i didnt delete it lol and they made it on replit


Well they would lose that lawsuit. You should give others credit but legally you don’t have to.


yeah i neaver even took out their credits i just changed some css and added a few items to the shop and they got all mad i was 15 at the time of this lol and im pretty sure they are a minor also so they couldnt even sue me they were just mad that my revision of it was more popular than theirs