In this task, you are given two lists A,B. Find the longest common subsequence in the lists A and B.
[1679, 2617, '9173', '6397', 'W', 'q', 5635], ['P', 4595, 5285, '9173', '6397', 'W', 'X', 8873, 'r']