Code for the COMP1007 course