Jul-28-2019, 10:35 AM
All objects inherit from
The normal use is:
object
. Testing objects against object
should be always True
, even if you check type
against object
.The normal use is:
my_object = [1, 2, 3] print(isinstance(my_object, list)) print(isinstance(my_object, tuple))
Output:True
False
Almost dead, but too lazy to die: https://sourceserver.info
All humans together. We don't need politicians!
All humans together. We don't need politicians!