Consider
List<string> s=new List<string>();
s.Add("one");
List<string> p=new List<string>();
p.Add("one");

What should be written in the braces?

if (s==p)
{

}

 Posted by Ddd on 1/27/2011 | Category: C# Interview questions | Views: 9829 | Points: 40
Select from following answers:
  1. Console.WriteLine("equal");
  2. Console.WriteLine("unequal");
  3. None of these
  4. All Above

Show Correct Answer


Asked In: Many Interviews | Alert Moderator 

Comments or Responses

Posted by: Santoshkumar on: 4/28/2011 | Points: 10
correct answer is
console.WriteLine("equal");
plz correct the answer.
Posted by: Santoshkumar on: 4/28/2011 | Points: 10
Hey i am sorry it is incorrect answer.
what i wrote.

Posted by: Prasad_N on: 1/3/2012 | Points: 10
I have executed the code.. the Condition fails..so the answer is Unequal..Only.

Login to post response