For Two Strings S1 And S2 To Be Equal Which Is The Correct Way #33
For two strings s1 and s2 to be equal, which is the correct way to find if the contents of two strings are equal?
This multiple choice question (MCQ) is related to the book/course gs gs108 CSharp. It can also be found in gs gs108 Data Types, Variables and Operators - Char Types and String Literals - Quiz No.1.
For two strings s1 and s2 to be equal, which is the correct way to find if the contents of two strings are equal?
if(s1 = s2)
int c; c = s1.CompareTo(s2);
if (s1 is s2)
if(strcmp(s1, s2))