# intersection of two lists (lst1 & lst2) In [1]: x = ["a", "b", "c", "d", "e"] In [2]: y = ["f", "g", "h", "c", "d"] In [3]: set(x).intersection(y) Out[3]: {'c', 'd'} # has_intersection = bool(set(x).intersection(y)) -> True