Python does not ship with only two objects. Oh no, the two primitives
come with a whole gang of buddies.
A few built-in types are shown above, and examined below.
Example 2.3. Examining some built-in types
>>> list<type 'list'> >>> list.__class__
<type 'type'> >>> list.__bases__
(<type 'object'>,) >>> tuple.__class__, tuple.__bases__
(<type 'type'>, (<type 'object'>,)) >>> dict.__class__, dict.__bases__
(<type 'type'>, (<type 'object'>,)) >>> >>> mylist = [1,2,3]
>>> mylist.__class__
<type 'list'>
When we create a tuple or a dictionary, they are instances of the respective type objects.
So how can we create an instance of
mylist? We cannot. This is because
mylist is a non-type object.
We are now in a position to better define type objects.
Type Or Non-type Test Rule
If an object is an instance of <type 'type'>, then it is
a type object. Otherwise, it is a non-type object.
Looking back, we can verify that this is true for all objects we have come across.

<type 'list'>
>>> list.__class__
<type 'type'>
>>> list.__bases__
(<type 'object'>,)
>>> tuple.__class__, tuple.__bases__
(<type 'type'>, (<type 'object'>,))
>>> dict.__class__, dict.__bases__
(<type 'type'>, (<type 'object'>,))
>>>
>>> mylist = [1,2,3]
>>> mylist.__class__
<type 'list'>