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 / b2balaji

shall u give reason for this answer?

Is This Answer Correct ?    0 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

If you donot specify an access modifier for a method, what is the default access modifier?

524


What is the example of predicate?

480


How many static constructors are allowed in a class?

458


What are partial types in c#?

466


Can you inherit from a sealed class?

465






How does dependency injection work c#?

482


Why do we use static class in c#?

467


Explain partial class in c#?

478


List the differences between method overriding and method overloading?

471


What is mvc in c#?

442


What are Uses of CLR

516


What debugging tools come with the .NET ssSDK?

668


What is Assembly. and Describe type of assembly. why most developer happy with private assembly.

557


Can we have multiple threads in one app domain?

503


Is c# different than c++?

497