Final Working version of cachematrix.R for Assignment #2