Updated Cachematrix.R with my code