In the following C# code, which of the following statements are perfectly valid? 1. public class MyContainer where T: IComparable 2. { 3. /* insert code here */ 4. }
A Class MyConatiner requires that its type argument must implement Icomparable interface
B There are multiple constraints on type argument to MyContainer class
C Type argument of class MyContainer should be Icomparable
D None of the mentioned
Answer:C
In the following C# code, which of the following statements are perfectly valid? 1. public class MyContainer where T: IComparable 2. { 3. /* insert code here */ 4. }
A Class MyConatiner requires that its type argument must implement Icomparable interface B There are multiple constraints on type argument to MyContainer class C Type argument of class MyContainer should be Icomparable D None of the mentioned