Tell me real world example of polymorphism and encapsulation .
Answers were Sorted based on User's Feedback
Answer / sp
Polymorphism can be considered as a Married man. Who acts
differently in different situation , he acts as a son to
his father and the same person acts as father to his
son .That is he plays , different roles in different
|Is This Answer Correct ?||118 Yes||10 No|
Answer / pankaj
Rael world example fo polymorphism can be start machnism of
bike, inwhich u wil hav same method start() but it may be
either by kick start or button start.
N example for encapsulation can be a stack or queue doesn't
matter how it is implented internally with linked list or array
|Is This Answer Correct ?||64 Yes||27 No|
Answer / rexreno
polymorphism can be describe as a key in our mobile phone,
if we press key one time it write say "m" and if 2 times it
same key implementing different tasks.
|Is This Answer Correct ?||46 Yes||11 No|
Answer / dd
Real example of polymorohism--
Ur mobile phone..
one name but many forms..
as mp3 player
|Is This Answer Correct ?||42 Yes||9 No|
Answer / shashank
polymorphism real life example:
a software engineer performs many task such as sometimes he performs coding, sometimes he performs testing, sometimes he performs analyzing. so software eng. is one but he is performing different task depending upon time.
|Is This Answer Correct ?||16 Yes||6 No|
Answer / sharuq
take a boy. at home he is a son and at school he is student
take a car we can see only body of the car but not engine
|Is This Answer Correct ?||1 Yes||0 No|
Answer / nagaraj
polymorphisms is nothing but ability to take more than one forms(One Interface,Multiple Methods or One Name,Many Forms).
-is nothing but wrapping the data and functions into single entity.
The Process of deriving new class from existing class.This is called Inheritance.
New Class-Child Class
Existing Class-Parent Class
say a door..
a door to a temple, a door to a house, a door to a kitty house,
all are doors, but all look different
cars and owners...
all the functions of cars are encapsulated with the owners..
No one else can access it...
|Is This Answer Correct ?||1 Yes||1 No|
Answer / srikanth reddy
Polymorphysam it means :One thing Menyforms ex: money y bcoz money is one thing it can useful for us food, travel, shoping, rent ex...
|Is This Answer Correct ?||0 Yes||1 No|
Answer / m.arunachalam
Examples of Polymorphism : Consider a Crocodile... It's live
in water and land.......
|Is This Answer Correct ?||9 Yes||16 No|
Answer / abhishek
real example is our eyes work seen the object in light, and
work not seen object in dark .
|Is This Answer Correct ?||4 Yes||18 No|
what is the different between B-tree and B+ tree.
Why enum can not be used directly with printf function?
What is the average number of comparisons in a sequential search?
what is AVL tree?
No. of possible ordered trees with n nodes ? Please give formula (if any).
applications of stacks and their uses?
what is mean by d-queue?
What do you mean by: Syntax Error, Logical Error, Runtime Error?
do records fall under linear or non linear data structures?
1) Program A and B are analyzed and found to have worst- case running times no greater than 150nlog2n and n2 respectively.Answer the folloWing questions if possible.. i) which program has the better guarantee on the running time,for larger values of n(n>10000) ? ii) which program has the better guarantee on the running time,for small values of n(n<100) ? iii) which program will run faster on average for n =1000 2) wRite a program to compute the number of collisions required in a long random sequence of insertions using linear probing ,quadratic probing and double hashing 3) what is the optimal way to compute A1 A2 A3 A4 A5 A6 where the dimensions of the matrices are A1:10*20 A2 : 20 * 1 A3 : 1 * 40 A4 : 40*5 A5 : 5 * 30 A6 : 30 X 15
sir plz. send me a bunch of questions related to this topic which may help me in campus selection
Write a Binary Search program