In this task, you are given two lists A,B. Find the longest common subsequence in the lists A and B.
['y', 5157, 'D', 'h', 'q', '4149', '7951', 'q', 9815, 9503], [1123, 'U', 'h', 'q', '4149', '7951', 'Q', 'a']