how to check if var is iterable in python code example
Example: python check if variable is iterable
from collections import Iterable
def iterable(obj):
return isinstance(obj, Iterable)
from collections import Iterable
def iterable(obj):
return isinstance(obj, Iterable)