Python 判断类型
类型判断:isinstance(obj, type)
方法 : isinstance(obj, type) print (isinstance(3, int)) # True print (isinstance(3, str)) # False print (isinstance(3, list)) # False print (isinstance([1,2,3], list)) # True print (isinstance(datetime.datetime.now(),datetime.date)) # True