Code from CSSE2310 course (2012)