how to see if element if string obj python code example Example: is instance string python isinstance(x, int) isinstance(s, str)