Modified default cachematrix.r with code to complete assignment