Hi, ı have some problem with my dynamic programming assignment. I can do it by using c. But ı don't know how to use dynamic programming.
In the assignment we are asking to find the maximum sequence in a list (such as longest common subsequence)
we have to write an application to decide which group to pick to get the maximum number of subsequence. If we take from one number we can not take from its immediate neighbors.The input will be an array with maximum 40 elements.However we have to do it with dynamic programming.
Example:
insert
Code:
Input: {4,12} Returns: 12
Input: {10,12,1} Returns: 12
Input: {1,1,4,4,6,1,1,3,4,6} Returns: 20 – 1,4,6,3 and 6 are picked.
Please help me