Coded the makeCacheMatrix and cacheSolve functions.