Copy and Paste Programming - Plagiarism

Plagiarism

Copy and pasting is often done by inexperienced or student programmers, who find the act of writing code from scratch difficult and prefer to search for a pre-written solution or partial solution they can use as a basis for their own problem solving. (See also Cargo cult programming)

Inexperienced programmers who copy code often do not fully understand the pre-written code they are taking. As such, the problem arises more from their inexperience and lack of courage than from the act of copying and pasting, per se. The code often comes from disparate sources such as friends' or co-workers' code, Internet forums, code provided by the student's professors/TAs, or computer science textbooks. The result risks being a disjointed clash of styles, and may have superfluous code that tackles problems for which solutions are no longer required.

A further problem is that bugs can also easily be introduced by assumptions and design choices made in the separate sources that no longer apply when placed in a new environment.

Such code may also, in effect, be unintentionally obfuscated, as the names of variables, classes, functions, etc., are typically left unchanged, even though their purpose may be completely different in the new context from what it was in the original context.

Read more about this topic:  Copy And Paste Programming

Famous quotes containing the word plagiarism:

    Mr. Fitzgerald—I believe that is how he spells his name—seems to believe that plagiarism begins at home.
    Zelda Fitzgerald (1900–1948)

    Ideas improve. The meaning of words participates in the improvement. Plagiarism is necessary. Progress implies it. It embraces an author’s phrase, makes use of his expressions, erases a false idea, and replaces it with the right idea.
    Guy Debord (b. 1931)