63.
What are the advantages of the named iterator?

64.
The wrong statements about a HashTable collection are?

65.
What will be the output of the following C# code snippet?
class A
{
    int i;
    int j;
    public A()
    {
        i = 1;
        j = 2;
    }
}
class Program
{
    static void Main(string[] args)
    {
       A obj1 = new A();
       Console.WriteLine(obj1.ToString());
       Console.ReadLine();
    }
}

66.
What will be the output of the following C# code snippet?
class access
{
    public int x;
    private int y;
    public  void cal(int a, int b)
    {
        x = a + 1;
        y = b;
    }
    public  void print() 
   {
       Console.WriteLine(" " + y);     
   } 
}    
class Program
{
    static void Main(string[] args)
    {
        access obj = new access();   
        obj.cal(2, 3);
        Console.WriteLine(obj.x);
        obj.print();
        Console.ReadLine();
    }
}

67.
What will be the output of the following C# code snippet?
static void Main(string[] args)
{
    string s = " i love you";
    Console.WriteLine(s.IndexOf('l') + "  " + s.lastIndexOf('o') + "  " + s.IndexOf('e'));
    Console.ReadLine();
}

68.
What will be the output of the following C# code snippet?
class Program
{
    static void Main(string[] args)
    {
        String s1 = "CSHARP";
        String s2 = s1.Replace('H','L');
        Console.WriteLine(s2);
        Console.ReadLine();
    }
}

70.
What will be the output of the following C# code snippet?
class MyClass
{
    char[] chrs = { 'A', 'B', 'C', 'D' };
    public System.Collections.IEnumerator GetEnumerator()
    {
        foreach (char ch in chrs)
        yield return ch;
    }
}
class Program
{
    static void Main(string[] args)
    {
        MyClass mc = new MyClass();
        foreach (char ch in mc)
        Console.Write(ch + " ");
        Console.WriteLine();
        Console.ReadLine();
    }
}

Read More Section(Miscellaneous in C Sharp)

Each Section contains maximum 100 MCQs question on Miscellaneous in C Sharp. To get more questions visit other sections.