Skip to content

Commit b185518

Browse files
committed
Typo fixed, more comments added.
1 parent 483a2cb commit b185518

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

cachematrix.R

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
1-
## funtcion makeCacheMatrix() creates a special "matrix" object that can cache its inverse.
1+
## function makeCacheMatrix() creates a special "matrix" object that can cache its inverse.
2+
## There are several functions:
3+
## 1. set the value of the matrix
4+
## 2. get the value of the matrix
5+
## 3. set the inverse of the matrix
6+
## 4. get the inverse of the matrix
7+
28
makeCacheMatrix <- function(x = matrix()) {
39
m <- NULL
410
set <- function(y) {
@@ -19,7 +25,7 @@ makeCacheMatrix <- function(x = matrix()) {
1925
cacheSolve <- function(x, ...) {
2026
m <- x$getInverse()
2127

22-
## Return a matrix that is the inverse of 'x' if the inverse has already been calculated and cached.
28+
## Return a matrix that is the inverse of 'x' if the inverse has already been calculated and cached.
2329
if(!is.null(m)) {
2430
message("getting cached data")
2531
return(m)

0 commit comments

Comments
 (0)