R code for makeCacheMatrix and cacheSolve functions