cachematrix.R edited with completed Programming Assignment 2