Dynamic Programming 7

0. An algorithm to find the length of the longest monotonically increasing sequence of numbers in an array A[0: n-1] is given below.
Let Li denotes the length of the longest monotonically increasing sequence starting at index i in the array
Initialize Ln – 1 = 1
For all i such that 0 ≥ i ≥ n – 2

 Finally the length of the longest monotonically increasing sequence is Max(L0, L1, ......, Ln+1).
 Which of the following statements is TRUE?

  • Option : A
  • Explanation :
    The Algorithm uses dynamic programming approach.
Cancel reply

Your email address will not be published. Required fields are marked *


Cancel reply

Your email address will not be published. Required fields are marked *