Knapsack added. LCS updated to handle special cases
 Knapsack added. LCS updated to handle special cases-1
 Knapsack added. LCS updated to handle special cases-2