Duplicate Code - How Duplicates Are Created

How Duplicates Are Created

There are a number of reasons why duplicate code may be created, including:

  • Copy and paste programming, in which a section of code is copied "because it works". In most cases this operation involves slight modifications in the cloned code such as renaming variables or inserting/deleting code.
  • Functionality that is very similar to that in another part of a program is required and a developer independently writes code that is very similar to what exists elsewhere.
  • Plagiarism, where code is simply copied without permission or attribution.

Read more about this topic:  Duplicate Code

Famous quotes containing the word created:

    Yet the wound, O see the wound
    This petrified heart has taken,
    Because, created deathless,
    Nothing but death remained
    To scatter magnificence....
    Philip Larkin (1922–1986)