What will be the output of the following C# code snippet? [code] { delegate string F(string str); class sample { public

What will be the output of the following C# code snippet?
Code:
{
    delegate string F(string str);
    class sample
    {
        public static string fun(string a)
        {
            return a.Replace(',''-');
        }
    }
    class Program
    {
        static void Main(string[] args)
        {
            F str1 = new F(sample.fun);
            string str = str1("Test Your c#.NET skills");
            Console.WriteLine(str);
        }
    }
}
A. Test Your
B.
Code:
Test-Your-C#.NET-Skills
C. ur C#.NET Skills
D. None of the mentioned
 

Tìm kiếm

Back
Top