Longest Common Subsequence

This script executes a dynamic programming algorithm for the Longest Common Subsequence problem. Users should enter two sequences (or just go with the randomly generated sequences) and press the calculate button. Once this button is pressed the algorithm will operate based on the following table:

LCS(Xi, Yj) =
0, if i is 0 or j is 0
1 + LCS(Xi-1, Yj-1) if Xi equals Yj
max(LCS(Xi-1, Yj), LCS(Xi, Yj-1))