Update cachematrix.R

This is my update to complete Programming Assignment 2