Part 1. Definition
In this task, you are given two lists A,B. Find the longest common subsequence in the lists A and B.
Part 2. Example
[5797, 8817, '8297', 'b', 'U', 'b'], [5843, 8809, '8297', 'b', 'W', 'C']
Answer: 8297, b
Explanation: Here, '8297, b' is the longest common subsequence in both the input lists [5797, 8817, '8297', 'b', 'U', 'b'] and [5843, 8809, '8297', 'b', 'W', 'C'].
Part 3. Exercise
[7965, 'U', 4451, 'j', 'y', 'I', 't', 'q', 3689, 449, 1413, 8551, 'H', 421, 'Q', '135', '4093', '9889', '1423', 'M', '329', 'z', '4891', '4217', '1747', 'v', '9969', 'G', 'X', '1443', '4107', 'r', 'G', 'd', 4393, 9869, 'L', 'C', 'n', 'l', 8477, 2259, 'h', 4169, 'q', 4655, 'S'], [2491, 'M', 'r', 'I', 'W', 9415, 7187, 1711, 7221, 2281, 5695, 6749, '135', '4093', '9889', '1423', 'M', '329', 'z', '4891', '4217', '1747', 'v', '9969', 'G', 'X', '1443', '4107', 'r', 'd', 3641, 1449, 6573]
Answer:
135, 4093, 9889, 1423, M, 329, z, 4891, 4217, 1747, v, 9969, G, X, 1443, 4107, r