makeCacheMatrix() and cacheSolve() implementation