implementation of makeCacheMatrix & cacheSolve