21 real Equality & Strings questions from the C# bank, as asked in Indian campus drives and tech interviews. Every question has a verified answer and an AI-tutor explanation on placd — free to start.
1. What is Reference equality default?
Mid
A.the property that text instances cannot be changed after creation, so any apparent modification produces a new instance
B.the behavior whereby the == operator on most classes compares whether two operands point to the same instance rather than comparing their contents
C.an argument modifier requiring the called method to assign the variable before returning, used to produce additional results
D.redefining the inherited content-comparison method (and the matching hash method) so instances are considered equal based on their values rather than identity
2. Which term means: "the behavior whereby the == operator on most classes compares whether two operands point to the same instance rather than comparing their contents"?
A.Reference equality default — the behavior whereby the == operator on most classes compares whether two operands point to the same instance rather than comparing their contents
B.Reference equality default — an argument modifier requiring the called method to assign the variable before returning, used to produce additional results
C.Reference equality default — a mutable buffer type for efficiently composing text through many append operations without allocating a new instance each time
D.Reference equality default — the property that text instances cannot be changed after creation, so any apparent modification produces a new instance
A.the property that text instances cannot be changed after creation, so any apparent modification produces a new instance
B.redefining the inherited content-comparison method (and the matching hash method) so instances are considered equal based on their values rather than identity
C.the runtime optimization of storing a single shared copy of identical literal text so equal compile-time literals reference the same instance
D.an argument modifier requiring the called method to assign the variable before returning, used to produce additional results
A.String immutability — the behavior whereby the == operator on most classes compares whether two operands point to the same instance rather than comparing their contents
B.String immutability — redefining the inherited content-comparison method (and the matching hash method) so instances are considered equal based on their values rather than identity
C.String immutability — an argument modifier passing a variable by reference and requiring it be initialized beforehand, letting the method read and modify the caller's storage
D.String immutability — the property that text instances cannot be changed after creation, so any apparent modification produces a new instance
A.the property that text instances cannot be changed after creation, so any apparent modification produces a new instance
B.redefining the inherited content-comparison method (and the matching hash method) so instances are considered equal based on their values rather than identity
C.a mutable buffer type for efficiently composing text through many append operations without allocating a new instance each time
D.the runtime optimization of storing a single shared copy of identical literal text so equal compile-time literals reference the same instance
8. Which term means: "the runtime optimization of storing a single shared copy of identical literal text so equal compile-time literals reference the same instance"?
A.String interning — the runtime optimization of storing a single shared copy of identical literal text so equal compile-time literals reference the same instance
B.String interning — the property that text instances cannot be changed after creation, so any apparent modification produces a new instance
C.String interning — a mutable buffer type for efficiently composing text through many append operations without allocating a new instance each time
D.String interning — an argument modifier requiring the called method to assign the variable before returning, used to produce additional results
11. Which term means: "a mutable buffer type for efficiently composing text through many append operations without allocating a new instance each time"?
A.StringBuilder — the property that text instances cannot be changed after creation, so any apparent modification produces a new instance
B.StringBuilder — an argument modifier passing a variable by reference and requiring it be initialized beforehand, letting the method read and modify the caller's storage
C.StringBuilder — the behavior whereby the == operator on most classes compares whether two operands point to the same instance rather than comparing their contents
D.StringBuilder — a mutable buffer type for efficiently composing text through many append operations without allocating a new instance each time
A.the runtime optimization of storing a single shared copy of identical literal text so equal compile-time literals reference the same instance
B.an argument modifier requiring the called method to assign the variable before returning, used to produce additional results
C.redefining the inherited content-comparison method (and the matching hash method) so instances are considered equal based on their values rather than identity
D.the behavior whereby the == operator on most classes compares whether two operands point to the same instance rather than comparing their contents
A.Out parameter — an argument modifier requiring the called method to assign the variable before returning, used to produce additional results
B.Out parameter — redefining the inherited content-comparison method (and the matching hash method) so instances are considered equal based on their values rather than identity
C.Out parameter — the runtime optimization of storing a single shared copy of identical literal text so equal compile-time literals reference the same instance
D.Out parameter — an argument modifier passing a variable by reference and requiring it be initialized beforehand, letting the method read and modify the caller's storage
A.the runtime optimization of storing a single shared copy of identical literal text so equal compile-time literals reference the same instance
B.an argument modifier passing a variable by reference and requiring it be initialized beforehand, letting the method read and modify the caller's storage
C.an argument modifier requiring the called method to assign the variable before returning, used to produce additional results
D.a mutable buffer type for efficiently composing text through many append operations without allocating a new instance each time
17. Which term means: "an argument modifier passing a variable by reference and requiring it be initialized beforehand, letting the method read and modify the caller's storage"?
A.Ref parameter — an argument modifier passing a variable by reference and requiring it be initialized beforehand, letting the method read and modify the caller's storage
B.Ref parameter — an argument modifier requiring the called method to assign the variable before returning, used to produce additional results
C.Ref parameter — the behavior whereby the == operator on most classes compares whether two operands point to the same instance rather than comparing their contents
D.Ref parameter — redefining the inherited content-comparison method (and the matching hash method) so instances are considered equal based on their values rather than identity
A.the runtime optimization of storing a single shared copy of identical literal text so equal compile-time literals reference the same instance
B.an argument modifier requiring the called method to assign the variable before returning, used to produce additional results
C.a mutable buffer type for efficiently composing text through many append operations without allocating a new instance each time
D.redefining the inherited content-comparison method (and the matching hash method) so instances are considered equal based on their values rather than identity
20. Which term means: "redefining the inherited content-comparison method (and the matching hash method) so instances are considered equal based on their values rather than identity"?
A.Equals override — an argument modifier requiring the called method to assign the variable before returning, used to produce additional results
B.Equals override — the behavior whereby the == operator on most classes compares whether two operands point to the same instance rather than comparing their contents
C.Equals override — redefining the inherited content-comparison method (and the matching hash method) so instances are considered equal based on their values rather than identity
D.Equals override — a mutable buffer type for efficiently composing text through many append operations without allocating a new instance each time
Answers, AI explanations, and a scored voice mock interview
Sign up free to check your answers with explanations, ask the AI tutor anything on any question, and take one full AI mock interview — scored like a real panel.