function makeCacheMatrix and Cachesolve

Written the function in R