Horje
polymorphism in C# Code Example
polymorphism in C#
using System;

namespace polymor
{
    class Program
    {
        void Sum(int a, int b)
        {
            Console.WriteLine(a + b);
        }
       
        void Sum(int a, int b, int c)
        {
            Console.WriteLine(a + b + c);
        }
        void Sum(int a, int b, int c, int d)
        {
            Console.WriteLine(a + b + c + d);
        }
        static void Main(string[] args)
        {
           
           
            Program obj = new Program();
            obj.Sum(2,3);
            obj.Sum(2,3,4);
            obj.Sum(2, 3, 4,5);
            Console.ReadLine();
        }
    }
}




Csharp

Related
c# Math.Sqrt Code Example c# Math.Sqrt Code Example
select distinct linq mvc Code Example select distinct linq mvc Code Example
get first number in string C# Code Example get first number in string C# Code Example
create new gameobject unity Code Example create new gameobject unity Code Example
unity check if current scene is being unloaded Code Example unity check if current scene is being unloaded Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
9