Skip to content

Commit cc54bc0

Browse files
committed
Fix mixed identation (converted all to tabs)
1 parent 621e281 commit cc54bc0

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

cachematrix.R

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -15,33 +15,33 @@ CachedOps <- setRefClass("CachedOps",
1515

1616
methods = list(
1717
initialize = function(expr,...){
18-
cached <<- FALSE
19-
result <<- function(){
20-
cached <<- TRUE
21-
expr
22-
}
18+
cached <<- FALSE
19+
result <<- function(){
20+
cached <<- TRUE
21+
expr
22+
}
2323
callSuper(...)
2424
},
2525

2626
getResult = function(){
2727
"Calculating result of operation on matrix.
2828
Once it was calculated result is cached and returned in any consecutive call"
29-
if(cached) message("getting cached data")
29+
if(cached) message("getting cached data")
3030
result()
3131
})
3232
)
3333

3434
makeCacheMatrix <- function(expr,...) {
35-
# Creating new caching object
36-
# Args:
37-
# func - function, result of calculation is need to cache
38-
# ... - parameters for function calling
35+
# Creating new caching object
36+
# Args:
37+
# func - function, result of calculation is need to cache
38+
# ... - parameters for function calling
3939
CachedOps$new(expr,...)
4040
}
4141

4242
cacheSolve <- function(x) {
43-
# Calculating result of function on matrix
44-
# once it was calculated result is cached
45-
# and returned in any consecutive call
43+
# Calculating result of function on matrix
44+
# once it was calculated result is cached
45+
# and returned in any consecutive call
4646
x$getResult()
4747
}

0 commit comments

Comments
 (0)