Quiz Yourself: Interfaces
Test your knowledge of interface syntax, inheritance rules, and generic implementations in C#.
We'll cover the following...
We'll cover the following...
Technical Quiz
1.
Consider the code below where ISerializable inherits from two other interfaces. How many total interfaces must MyClass satisfy to compile successfully?
public interface IDisposable { void Dispose(); }
public interface ICloneable { object Clone(); }
public interface ISerializable : IDisposable, ICloneable { void Serialize(); }
public class MyClass : ISerializable
{
// Implementation details...
}
A.
One
B.
Two
C.
Three
D.
Zero
1 / 12
...