isinstance(your_var, basestring)
More Related Contents:
- how to unpack a tuple in this form (‘abc’, [20, 20])? [closed]
- Pandas column of lists, create a row for each list element
- What is the difference between `sorted(list)` vs `list.sort()`?
- Converting a string representation of a list into an actual list object [duplicate]
- Why can tuples contain mutable items?
- Why does ‘.sort()’ cause the list to be ‘None’ in Python? [duplicate]
- Python’s insert returning None?
- How to convert list of key-value tuples into dictionary?
- Finding index of an item closest to the value in a list that’s not entirely sorted
- How to convert a list to a list of tuples?
- appending list but error ‘NoneType’ object has no attribute ‘append’ [duplicate]
- How to input matrix (2D list) in Python?
- Combining Dictionaries Of Lists In Python
- Check if list items contains substrings from another list
- accepting multiple user inputs separated by a space in python and append them to a list
- Why do these list operations (methods: clear / extend / reverse / append / sort / remove) return None, rather than the resulting list?
- Comprehension on a nested iterables?
- Slicing a list into n nearly-equal-length partitions [duplicate]
- Overriding append method after inheriting from a Python List
- Can lists be mutated? [duplicate]
- How to return all list elements of a given length?
- List extending strange behaviour [duplicate]
- Find all index position in list based on partial string inside item in list
- Python recursive function to display all subsets of given set
- Creating sublists [duplicate]
- Can’t sort my list because it is NoneType? Simple Python [duplicate]
- How to sort a list of dictionaries by a value of the dictionary in Python?
- Python: Random numbers into a list
- How to create a nested dictionary from a list in Python?
- Store functions in list and call them later [duplicate]