Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Python by (19.9k points)

Given two lists, can we obtain all the elements that are present in one list but not there in another?

1 Answer

0 votes
by (25.1k points)
edited by

You can do it like this:

difference = list(set(list1) - set(list2))

You can learn more about python by watching this youtube video: 

Related questions

Browse Categories

...