“StaticFieldInGenericType” (Problem)

What will the following code display?

class Foo<T>
{
  public static int Bar;
}
void Main()
{
  Foo<int>.Bar++;
  Console.WriteLine(Foo<double>.Bar);
}

Solution

Last updated