Code Extracts

It can be useful to include some code extracts in your project report. Sometimes these might be in the body of your report or these might be in the Appendices. When thinking about how you present such code extracts, consider the following.

  • If an extract isn’t discussed in the body of the report, it does not need to be included in your report.

  • If an extract is discussed, consider where it is included:

    • Short extracts can be included in the body of the report. A short extract would normally fit on one page. It should be included next to the discussion about the item.

    • Longer extracts can be better in the Appendices. A longer extract would occupy more than one page. The discussion in the body of the report should refer the reader to the appendix that includes the longer extract.

Do not include your full code listing in an appendix. The Technical Submission is where we would expect to see all of your code, configuration and related work.

If certain items are boiler-plate they probably do not need much discussion. Further, they probably do not need to be shown in the body of the report. An example might be configuration files that need to exist in a particular format and location for a system to work. If you had to make notable changes to such files, particularly where the changes are not obvious, they might benefit from inclusion in the report and some discussion.

Note

For some projects, the algorithm (how something is done) is of more interest than the code that implements the algorithm. In that case, describing the algorithm as pseudocode may be better than including the code.

We don’t need to see all lines of code discussed. It is good to see some code examples for the particularly interesting and advanced parts of your system. Like most things for report writing, it is a question of balance. If you have questions about this, then you can speak to your supervisor or the module coordinator for advice.