Implemented cacheSolve

Implemented cacheSolve, which assumes that all inputs are invertible