Adarsh Raj wrote:if every class in java automatically extends the base class Object, how is it possible to write such as
concerning the fact that, java allows at a time only one class to be extended.
Its like SomeClass extends AnotherClass and AnotherClass extends Object class. So at a time one class is extending single class. If you do not extend any class compiler inherits Object class by default.