Given that Memoization is a computing strategy that is applied in storing the previously calculated values such that values can easily be recalled to execute similar problems or further problems. It is also used in making recurring algorithms productive
Hence, in this case, In dynamic programming, the technique of storing the previously calculated values is referred to as MEMOIZATION
Restore is a procedure to copy one or more files from backup media to the original disk or a replacement disk when data or programs have been erased or destroyed.
Following are attached images that will help you understand the complete code. The code is tested with different variables and different outputs are obtained. All the necessary description is given in the form o comments inside the code.