You will be given a definition of a task first, then some input of the task.
In this task, you are given two lists A,B. Find the longest common subsequence in the lists A and B.

[10017, 3747, 263, 7739, 'r', 7731, 'i', 9631, 5327, 'I', 4529, 7107, 'w', 'w', 617, 'A', 'R', 8345, 'm', 5411, 'y', 'J', '6907', 'Y', '3177', '6465', '377', 'V', '6735', 'o', '2647', 'F', 'u', '585', '6709', 'G', '223', '7431', '8827', '3701', 'P', '8885', 'x', 2757, 'i', 'G', 639, 6187, 503, 6167, 'a', 3877, 4925, 'q', 8775, 2871, 3997, 2859], [6617, 791, 'a', 6581, 'a', 5027, 3089, 'M', 7983, 2871, 5463, 'C', 'A', 2201, 5013, 'h', 7399, 3027, 2265, 'J', '6907', 'Y', '3177', '6465', '377', 'V', '6735', 'o', '2647', 'F', 'u', '585', '6709', 'G', '223', '7431', '8827', '3701', 'P', '8885', 'E', 'e', 325, 'S', 9495, 'y', 6403, 'T', 6329, 6523, 'e', 7187, 5381, 'C']
Output:
J, 6907, Y, 3177, 6465, 377, V, 6735, o, 2647, F, u, 585, 6709, G, 223, 7431, 8827, 3701, P, 8885