C# Programming - Strings - Discussion
Discussion Forum : Strings - General Questions (Q.No. 1)
Which of the following statements are true about the C#.NET code snippet given below?
String s1, s2; s1 = "Hi"; s2 = "Hi";
- String objects cannot be created without using new.
- Only one object will get created.
- s1 and s2 both will refer to the same object.
- Two objects will get created, one pointed to by s1 and another pointed to by s2.
- s1 and s2 are references to the same object.
Discussion:11 comments Page 2 of 2.
SWATI said: 1 decade ago
HOW TO SOLVE THIS PROBLEM
Post your comments here: