Answer Posted / sitaram
Inheritance: The base class properties into subclass class
is called inheritance.
Inheritance example:Father and child relation. Father
having 10 lakhs property. That property is always avilable
to child. Father is a parent class. child is a subclass.
Advantage: 1.subclasss take the all properties from parent
class.
2.suppose you can add any property in parent class. That
will be effected to subclasses also.
Is This Answer Correct ? | 22 Yes | 2 No |
Post New Answer View All Answers
What is abstract class constructor called?
What are the 7 types of characters?
What’s the difference between the methods sleep() and wait()?
What about static nested classes in java?
who can i handle multiple client in RMI
Is java 9 released?
Can inner class extend any class?
Why string is immutable with example?
Why we do exception handling in java and how many types of exceptions are there?
extending thread class or implementing runnable interface. Which is better? : Java thread
What do you understand by classes in java?
How do you use substring in java?
What is a char in java?
What is singleton class in java and how can we make a class singleton?
Implement a stack with push (), pop() and min() in O(1) time.