Answers for "python filter list of int and strings"

1

python filter list of int and strings

def filter_list(l):
  'return a new list with the strings filtered out'
  return [i for i in l if not isinstance(i, str)]
Posted by: Guest on December-02-2020

Code answers related to "python filter list of int and strings"

Python Answers by Framework

Browse Popular Code Answers by Language