Answer Posted / kureshi salman
Inheritance means deriving a child class from a parent class
(i.e.existing class).
Use of inheritance iin java is we can reuse of a code.
For Ex.
class a
{
//variables.....
//methods.......
}
class b extends a
{
//variable of class a....
//methods of class a.....
//also
//variables and methods of class b
}
it means that we can inherit the class and features of
existing class in a new class.
Is This Answer Correct ? | 29 Yes | 3 No |
Post New Answer View All Answers
Does chrome use java?
Can you give few examples of final classes defined in java api?
How do you square a number in java?
How many types of flags are there?
What is the difference between multiple processes and multiple threads?
what is difference betweem home interface and remote interface?
How many types of array are there?
When we serialize an object does the serialization mechanism saves its references too?
How do you make an arraylist empty in java?
What is the byte range?
What are selection structures?
How do you get length in java?
Why do we need singleton?
What do you understand by access specifiers in Java?
Explain what access modifiers can be used for variables?