Initial submission

Functions updated in line with assignment instructions and tested