Programming Assignment2 cachematrix