Longest Common Subsequence

This commit is contained in:
AnupKumarPanwar
2017-04-10 14:31:19 +05:30
parent 92af829028
commit 41a5325709
4 changed files with 2 additions and 10 deletions

View File

@@ -18,10 +18,10 @@ int lcs(string a, string b){
}
return res[m][n];
}
int main(int argc, char const *argv[])
int main()
{
string a,b;
cin>>a>>b;
cout<<lcs(a,b);
return 0;
}
}

Binary file not shown.

View File

@@ -10,7 +10,6 @@ struct Item
float profitPerUnit(Item x)
{
// cout<<(float)x.profit/(float)x.weight<<"\n";
return (float)x.profit/(float)x.weight;
}
@@ -53,13 +52,6 @@ void quickSort(Item arr[], int low, int high)
// void show(Item arr[], int size)
// {
// for (int i=0; i < size; i++)
// cout<<arr[i].weight<<"\t"<<arr[i].profit<<"\n";
// }
int main()
{
cout<<"\nEnter the capacity of the knapsack : ";

Binary file not shown.