C# 7.0 quiz medium level


Test description

Put your C# know-how to the test and see how well you understand the C# programming language and some of the C# 7.0 new features. Topics: data types, collections, enumerations, operators, loops, and tuples.

Sample questions

1 Which of the following statements is valid for the code snippet below? 

class Base {}
class Derived : Base {}
static void Main(string[] args)
    Action<Base> b = (target) => { 
                 Console.WriteLine(target.GetType().Name); };
    Action<Derived> d = b;
    d(new Derived());