Complete cacheSolve and fix failue to set output to null in makeCacheMatrix