Update cachematrix.R

Updated cachematrix.R with required R functions and comments