# What exactly is the difference between:

class Test:
    pass

# and

class Test2(object):
    pass

# What exactly is the difference between:

class Test:
    pass

# and

class Test2(object):
    pass

If you use Python3 there is no difference other than the name of the class. That means class Test will automatically inherit objects.

In Python2 you can use for instance __slots__ to restrict class variable creation outside the 'new type' class Test2

So practically there are interchangeable, right?

If you use Python3
class Test2(object):
can simply be written
class Test2:
since Python3 will add the object inheritance internally anyway.