Update cachematrix.R

Updated Cachematrix.R final submission.