Memorizing Function Transformations