In this task, you are given two lists A,B. Find the longest common subsequence in the lists A and B.
[9861, 'O', 5705, 'q', 'p', 4227, 'i', 's', 'H', 'J', 'w', 'x', '9245', 'x', '4639', '8923', 'U', '4395', 'b', '3009', '9575', '9895', 'T', 'c', 'i', 'R', 'Q', 'Q'], [1187, 'o', 'D', 'B', 5263, 'Q', 4459, 'i', 's', 'H', 'J', 'w', 'x', '9245', 'x', '4639', '8923', 'U', '4395', 'b', '3009', '9575', '9895', 'T', 'T', 9479]