ExamVeda
Login
Home
61
Choose the namespace in which the interface IEnumerable is declared?
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
62
Select the Keyword which supports the run time type identification?
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
63
What will be the output of the following C# code snippet?
static void Main() 
{
    int[] nums = { 1, 2, 3, 4, 5 };
    Console.Write("Original order: ");
    foreach(int i in nums)
    Console.Write(i + " ");
    Array.Reverse(nums);
    Console.Write("Reversed order: ");
    foreach(int i in nums)
    Console.Write(i + " ");
    Console.WriteLine();
}
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
64
Choose the wrong statement about the LINQ?
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
65
What will be the output of the following C# code snippet?
class Program
{
    static void Main(string[] args)
    {
        int[] nums = { 1, -2, 3, 0, -4, 5};
        var posNums = from n in nums
                      where n >= 0
                      select n;
       foreach (int i in posNums) 
       Console.Write(i + " ");
       Console.WriteLine();
       Console.ReadLine();
   }
}
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board
66
Select the interfaces implemented by array class.
Discuss
Answer & Solution
Answer: Option D
No explanation is given for this question. Let's Discuss on Board
67
What will be the output of the following C# code snippet?
class Program
{
    static void Main(string[] args)
    {
        int[] nums = { 1, -2, 3, 0, -4, 5 };
        var posNums = from n in nums
                       where n > -5 && n < 6
                       orderby n descending
                       select n;
        Console.Write("The positive values in nums: ");
        foreach (int i in posNums) Console.Write(i + " ");
        Console.WriteLine();
        Console.ReadLine();
    }
}
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
68
Select the class which is the base class for all arrays in C#?
Discuss
Answer & Solution
Answer: Option A
No explanation is given for this question. Let's Discuss on Board
69
What will be the output of the following C# code snippet?
class Program
{
    static void Main(string[] args)
    {
        int[] nums = { 1, -2, 3, 0, -4, 5 };
        var posNums = from n in nums
                      where n % 2 ==0
                      select n;
           Console.Write("The positive values in nums: ");
           foreach (int i in posNums) Console.Write(i + " ");
           Console.WriteLine();
           Console.ReadLine();
       }
}
Discuss
Answer & Solution
Answer: Option C
No explanation is given for this question. Let's Discuss on Board
70
What will be the output of the following C# code snippet?
class Program
{
    static void Main(string[] args)
    {
        int[] nums = { 16,  9, 25};
        var posNums = from n in nums
                      where n > 0 
                      select Math.Sqrt(n);
 
        Console.Write("The positive values in nums: ");
        foreach (int i in posNums) Console.Write(i + " ");
        Console.WriteLine();
        Console.ReadLine();
    }
}
Discuss
Answer & Solution
Answer: Option B
No explanation is given for this question. Let's Discuss on Board