what is the purpose of class "Object" which is base class
for all classes?
Answer Posted / piryabrata patro
listen first , when you create object of one class which is not extending any class than , instead of one object , two object will be created and that is nothing but object of Object class and one more thing is no object is created with out it's superclass. So, object of subclass can not be created without it's superclass where Object class comes into picture because by default compiler gives Object class as superclass to all class which is not extending any class at compilation time itself.
| Is This Answer Correct ? | 4 Yes | 2 No |
Post New Answer View All Answers
What is a void in java?
What is java full form?
What is your platform?s default character encoding and how to know this?
Why we go for collections in java?
What is the difference between applet and application?
Is string a data type in java?
Define how does a try statement determine which catch clause should be used to handle an exception?
What is the formula to calculate percentage?
What happens to a static var that is defined within a method of a class?
How many arguments can be passed to main ()?
Can we override the private methods?
Where and how can you use a private constructor?
What is n in java?
What is singleton class in ruby?
What are the differences between string, stringbuffer and stringbuilder?