Question 1 of 5
When is caching a function result generally appropriate?
Trace what the cached function needs to do on the first call and on a repeated call.
Caching can skip the function body on a hit. It is best when the result is stable for the arguments and reusing the returned object is safe.
Review this lesson