Update cachematrix.R

two functions completed for programming assignment