- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- namespace Test
- {
- class Program
- {
- static void Main(string[] args)
- {
- //calling method
- DoSomething(1, "john", false);
- DoSomething(1, "john");
- DoSomething(id: 1, name: "john", status: false);
- DoSomething(name: "john", id: 1);
- DoSomething(name: "john", status: false, id: 1);
- }
- public static void DoSomething(int id, string name, bool status = true)
- {
- //Do something
- }
- }
- }