Hi, You can check for the "Animal" example at : http://www.learncpp.com/cpp-tutorial/121-pointers-and-references-to-the-base-class-of-derived-objects/ Although this example is in C++ it holds good for Java as well as Polymorphism applies both in C++ and Java. In C++ polymorphism is achieved through virtual functions.Hope this helps
________________________________ From: Tikeswar Mohanty <[email protected]> To: [email protected] Sent: Wed, 23 December, 2009 4:28:49 AM Subject: [java programming] real example of polymersim i want a real example of polymersim and also what is the advantage ? -- To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/javaprogrammingwithpassion?hl=en __________________________________________________________________________________ See what's on at the movies in your area. Find out now: http://au.movies.yahoo.com/session-times/ -- To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/javaprogrammingwithpassion?hl=en
