P=Assignment 2

R programming assignment 2 - caching by using lexical scoping