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 the purpose of checked and unchecked exceptions in JAVA?
What is the purpose of the System class?
What are the benefits of operations in java?
Why java is not 100% object-oriented?
Explain a situation where finally block will not be executed?
How do you reverse a list?
Addition to previous section relative word 5th one was Putrid ans: rotten, also there was prob. in 1st section on bucket weight ans:10kg, also there was a prob. on train speed to find bridge length ans:800 mtrs.
How do you declare an array that will hold more than 64KB of data?
What is the base class in java from which all classes are derived?
What are the types of strings?
If we don’t want some of the fields not to serialize how to do that?
what is synchronization? : Java thread
What is the difference between a synchronized method and a synchronized block?
What is a parameter used for?
Give the difference between the println method and sqrt method?