remove all numbers from list python code example
Example 1: remove all integers from list python
no_integers = [x for x in mylist if not isinstance(x, int)]
Example 2: how to remove a list of numbers from a list in python
>>>lst= set([1,2,6,8]) - set([2,3,5,8])
set([1, 6])
print(list(lst))
#output = [1,6]