Consider the following pieces of C# code:
a. interface I1 {/*......*/}
interface I2 {/*......*/}
struct Point : I1,I2 {/* ..... */}
b. struct Book{
int bookId;
struct Book b;
}
c. using M=Mystruct;
struct MyStruct{
int id;
}
class MyClass{
static void Main(string[] args){
M m = new M();
}
}
d. struct Sample{
Sample ref x;
}
Which of the above are correct?
Choose one of the options below.
a, c and d are right
a only right
a and c are right
d only wrong
None of the listed options
Answer Posted / sarang
a and c are right.
| Is This Answer Correct ? | 1 Yes | 2 No |
Post New Answer View All Answers
Where do we set the min and max pool size for connection pooling?
Is datetime immutable c#?
Explain what is an interface in c#?
What is the difference between “dispose” and “finalize” variables in c#?
Explain the process of polymorphism with an example?
What are actions in c#?
What is xml comments in c#?
What are the uses of delegates in c#?
What is the .net datatype that allows the retrieval of data by a unique key?
Explain how do you convert a value-type to a reference-type?
Describe the difference between inline and code behind - which is best?
Define MSIL, and how does it works? Why our developers need an appreciation of it if at all?
Explain the difference between user control and custom control. Also, explain their use.
Is hashset serializable c#?
What is hashtable c#?