In previous posts we have discussed many important topics of object oriented programming like classes, objects, inheritance etc. In this post we will discuss polymorphism in Java which is another important OOP concept. What is Polymorphism in Java? The word polymorphism means 'a state of having many shapes'. In terms of object oriented programming it's the ability to process objects of various types and classes through a single uniform interface. An object, variable or function may take on multiple forms / shapes and this phenomenon is known as Polymorphism. Example of Polymorphism in JAVA: [js] public int add(int a, int b){...
forward
Recent Comments
Archives
- November 2024
- July 2021
- December 2020
- November 2020
- September 2020
- August 2020
- July 2020
- April 2020
- March 2020
- February 2020
- January 2020
- December 2019
- October 2019
- April 2018
- March 2018
- February 2018
- January 2018
- December 2017
- November 2017
- March 2017
- January 2017
- December 2016
- November 2016
- October 2016
- June 2015
- May 2015
- April 2015