Closed khushibalyan220101 closed 3 years ago
@czgdp1807 sir I wanna contribute with this problem by creating a specific file for dynamic programming problems so that other important questions can be collected in a particular file.
This can go to the existing file, linear_data_structures.algorithms
under pydatastructs
since the algorithm you are suggesting is specific to linear data structures. Please go through the README for better understanding the workflow before submitting a PR.
P.S. I hope LCS is applicable to any kind of linear sequences and not necessarily strings.
Sure sir, I will go through the README.
LCS with BackTracking added in linerstruture->algorithms.py Test cases Added too "Fixes #310 "
Description of the problem LCS Problem Statement: Given two sequences, find the length of longest subsequence present in both of them. A subsequence is a sequence that appears in the same relative order, but not necessarily contiguous. Example of the problem For example, “abc”, “abg”, “bdf”, “aeg”, ‘”acefg”, .. etc are subsequences of “abcdefg”.