can u give some realtime example in ploymorphism? and
inheritance?
Answer Posted / abdulrazak
abstract class Person
{
public String sname(){}
Address ad;
}
class Patient extends Person
{
}
class Employee extends Person
{
}
Here in the above example Person is a class acting two ways
one Patient details info and Employee details. We are
achieving this extends Person i.e inheritence.Inheritence
provides code reusability,extensibility
| Is This Answer Correct ? | 10 Yes | 5 No |
Post New Answer View All Answers
What do you mean by default initialization in java servlet?
Why are servlets used?
How can you start a jta transaction from a servlet deployed on jboss?
What are the different session tracking techniques?
In the servlets, we are having a web page that is invoking servlets ,username and password? which is checks in database? Suppose the second page also if we want to verify
What are the type of protocols used in httpservlet?
When is the servlet instance created in the life cycle of servlet? What is the importance of configuring a servlet?
What is the dispatcher servlet?
What is servletconfig?
Differentiate between get and post?
What is called servlet container?
What is servlet initializer?
What are the common methods that are included in the http servlet class?
What is dispatcher servlet?
What are the disadvantages of storing session state in cookies?