Update dynamic_programming/cut_rod.cpp

Co-authored-by: David Leal <halfpacho@gmail.com>
This commit is contained in:
Pardeep Bhatt 2020-09-26 01:02:42 +05:30 committed by GitHub
parent 02cdd500c1
commit 9681e86569
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -36,6 +36,7 @@ namespace cut_rod {
/**
* @brief Cuts the rod in different pieces and
* stores the maximum profit for each piece of the rod.
* @tparam T description
* @param n size of the rod in inches
* @param price an array of prices that contains prices of all pieces of size<=n
* @return maximum profit obtainable for @param n inch rod.