Assignment 2 matrix cache functions coded and tested