end ? 另一种比较有用的实现重用的方法是记忆化(memoizing)。原理很简单:对于一个给定的某些输入值,保存其计算结果,当同样的值输入时,程序只需重用之前保存的结果。
双语例句
1
Memoizing a function adds a transparent caching wrapper to the function, so that function values that have already been obtained are returned from a cache rather than being rebuilt each time.