Skip to content

Commit c5fe276

Browse files
committed
Modified Version with better comments
1 parent 5bd2f30 commit c5fe276

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

‎cachematrix.R‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,10 @@ makeMatrix <- function(x = matrix()) {
1818
}
1919

2020

21-
# The following function calculates the inverse matrix of the special "matrix" created with the above function. However, it first checks to see if the inverse matrix has already been calculated. If so, it gets the inverse matrix from the cache and skips the computation. Otherwise, it calculates the inverse of the matrix and sets the value of the inverse_value in the cache via the setinverse function.
21+
# The following function calculates the inverse matrix of the special "matrix" created with the above function.
22+
# However, it first checks to see if the inverse matrix has already been calculated. If so, it gets the inverse matrix
23+
# from the cache and skips the computation. Otherwise, it calculates the inverse of the matrix and sets the value of the inverse_value in the cache via the
24+
# setinverse function.
2225

2326
cacheSolve <- function(x, ...) {
2427
## Return a matrix that is the inverse of 'x'

0 commit comments

Comments
 (0)