In this task, you are given two lists A,B. Find the longest common subsequence in the lists A and B.
['i', 4077, 'Z', 6231, 2337, 'h', '1181', '1631', '2605', '587', '1477', '2707', 'R', 'O', 'd', 1355, 'n'], [505, 'A', 8789, 75, 'q', 'h', '1181', '1631', '2605', '587', '1477', '2707', 'R', 'O', 'e', 'r', 'I', 'm', 1525, 3577]