if you don't explicitly write extends Object the compiler does it for you. So knowing that a class can only extend one super class, the compiler will look at the hierarchy and extend the highest super class to Object. So every class will directly or indirectly inherit the Object class.
The Object class however is a special case because it doesn't extend anything.
Lastly if you were to compile a simple class and decompile it, you will see the compiler inserts extends
java.lang.Object (or the bytecode equivalent) into the class.