State whether each of the following is true or false. If false, explain why. a) When strings
Question:
State whether each of the following is true or false. If false, explain why.
a) When strings are compared with ==, the result is true if the strings contain the same values.
b) A string can be modified after it’s created.
c) StringBuilder method EnsureCapacity sets the StringBuilder instance’s length to the argument’s value.
d) Method Equals and the equality operator work the same for strings.
e) Method Trim removes all whitespace at the beginning and the end of a string.
f) It’s always better to use strings, rather than StringBuilders, because strings containing the same value will reference the same object.
g) string method ToUpper creates a new string with the first letter capitalized.
Fantastic news! We've Found the answer you've been seeking!
Step by Step Answer:
Related Book For
Question Posted: