working version of makeCacheMatrix and cacheSolve