Posts

Showing posts with the label c#

Polymorphism in c# example source code

Image
Output: Source code: using System; namespace Inheritance {     // class are by default private it it     public class Shap     {         // if shap s= new shap();         // this this method call         public virtual double area()         {             return 0;         }                    }     public class Circle : Shap     {         // if shap s= new Circle();         // this this method call         public override d...