Skip to Main Content

Computer Science

A guide to research resources for computer science

Data Repositories

Online Source Code

Using source code without citing its source may be plagiarism. Below are some guidelines and resources.

As a general rule, if you have used a function or an algorithm that you did not create and it came from someone else, it should be cited. However, functions that would be considered "common knowledge" are an exception to this rule.

MIT provides a helpful online resource for code citation when writing code.

Citing Code In A Research Paper
Based on MLA citation rules, the citation should be formatted with the following information:
<author(s) names>. <source.extension>. <software package where code is found>, <version>, <publisher>, <date>. <website>, <URL>

Citing Code within Code
When citing code within code, the citation should be placed within a comment above the borrowed code as follows:

 <title of program/source code>
 <author(s) names>
 <date>
 <code version>
 <where the code was found>

Tutorials & Videos

Creative Commons   This work is licensed under a Creative Commons Attribution NonCommercial 4.0 International License. | Details of our policy