C# Programming - Strings - Discussion

Discussion Forum : Strings - General Questions (Q.No. 2)
2.
Which of the following will be the correct output for the C#.NET code snippet given below?
String s1 = "ALL MEN ARE CREATED EQUAL";
String s2;
s2 = s1.Substring(12, 3); 
Console.WriteLine(s2);
ARE
CRE
CR
REA
CREATED
Answer: Option
Explanation:
No answer description is available. Let's discuss.
Discussion:
12 comments Page 2 of 2.

Bharath said:   1 decade ago
Its substring right so its consider after 12 letters.

Mallu said:   1 decade ago
Can any body explain please?


Post your comments here:

Your comments will be displayed after verification.