{"push_id":947349184,"size":1,"distinct_size":1,"ref":"refs/heads/master","head":"6fb7bb048c17654067befb2f02ae27a41dcdbf81","before":"7f657dd22ac20d22698c53b23f0057e1a12c09b7","commits":[{"sha":"6fb7bb048c17654067befb2f02ae27a41dcdbf81","author":{"email":"ba9fc5441c49665e2f06d9b4620d9c534ca8dfa6@gmail.com","name":"TocoNero"},"message":"week3\n\n## Caching the Inverse of a Matrix:\n## Matrix inversion is usually a costly computation and there may be\nsome\n## benefit to caching the inverse of a matrix rather than compute it\nrepeatedly.\n## Below are a pair of functions that are used to create a special\nobject that\n## stores a matrix and caches its inverse.\n\n## This function creates a special \"matrix\" object that can cache its\ninverse,\n\nmakeCacheMatrix <- function(x=matrix()) {\ninv <- NULL\nset <- function(y) {\nx <<- y\ninv <<-NULL\n}\nget <- function() x\nsetInverse <- function() inv <<- inverse\ngetInverse <- function() inv\nlist(set= set,get= get,\nsetInverse= setInverse,\ngetInverse= getInverse)\n}\n\n## This fucntion computes the inverse of the special \"matrix\" created by\n## makeCacheMatrix above. If the inverse has already been calculated\n(and the\n## matrix has not changed), then it should retrieve the inverse from the\ncache.\n\ncachesolve <- function(x,...) {\ninv <- x$getInverse ()\nif(!is.null(m) {\nmessage(\"getting cached data\")\nreturn(inv)\n}\ndata <- x$get()\ninv <- solve(data,...)\nx$setInverse(inv)\n\ninv\n\n}","distinct":true,"url":"https://api.github.com/repos/TocoNero/ProgrammingAssignment2/commits/6fb7bb048c17654067befb2f02ae27a41dcdbf81"}]}