Examveda

What will be the output of the following C# code?
class Program
{
    static void Main(string[] args)
    { 
        String s1 = "I love You";
        String s2 = s1;
        Console.WriteLine((s1 == s2) + " " + s1.Equals(s2));
        Console.ReadLine();
    }
}

A. true true

B. false false

C. true false

D. false true

Answer: Option A


Join The Discussion

Related Questions on Arrays and Strings in C Sharp