implemented cacheSolve() and makeCachematrix() functions