Solved assignment 2 - i.e. edited cachematrix.R