how to check if iterable 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)