Tell me real world example of polymorphism and encapsulation .

Answer Posted / sharuq

polymorphism..
take a boy. at home he is a son and at school he is student
encapsulation..
take a car we can see only body of the car but not engine

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Tell us the difference between merge and quick sort. Which one would you prefer and why?

587


Does linkedhashset allow duplicates?

425


Who invented data structure?

633


List the area of applications of data structure.

766


Define depth and height of a node?

508






What are the complexity of binary search?

447


Describe binary tree and its property.

517


What is the capacity of arraylist?

469


What is the difference between an array and vector?

517


Define non-terminal nodes in a tree?

666


How many pointers are necessary to implement a simple linked list?

674


How does arraylist store data?

467


What is the difference between arraylist and array?

485


Can an arraylist be null?

468


Which interfaces are implemented by abstractqueue?

508