My cacheMatrix.R code

I checked this against the test cases posted on the discussion board by Community TA Gregory D. Horne under the discussion forum post titled "Hints for Programming Assignment 2 - Lexical Scoping" and I got all of the expected values.

I apologize for the long comments. I was trying to understand it myself, so it helped me to think through it and hopefully it will help anyone who struggled with the assignment to understand the logic of the functions better.