📌  相关文章
📜  如何检查一个列表是否包含另一个列表中的元素 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:23.524000             🧑  作者: Mango

代码示例1
##Taking examples of two python lists.

##Take examples of two lists.

list1 = [2,4,0,7,6]
list2 = [1,0,9,7,6]

##the statement for condition is.

check = any(element in list2 for element in list1)