In this task, you are given two lists A,B. Find the longest common subsequence in the lists A and B.
['P', 'X', '3051', 'r', 'g', '7807', 's', 4625, 'z'], [7583, 1013, '3051', 'r', 'g', '7807', 'I', 'R']