I am currently having two lists of tuples in Python, like:
A = [(1001, 'C:\\dd\fff'), (1002, 'C:\\dd\eee')]
B = [(1001, 'C:\\dd\fff'), (1002, 'C:\\dd\eee'), (1003, 'C:\\dd\ggg')]
The resultant list should only contain values from list B
which are not in list A
.
Tried with (set(A) - set(B))
, but due to second parameter as file path it's not providing correct result. Can someone please point out how to achieve this using Python?