Added code to cache inverse of a matrix.