C# in Depth

Cover of C# in Depth
Order now (3rd edition)

Lions and tigers and bears, oh my!

Chapter 3: Parameterized typing with generics: 3.6.1

Created: 2/22/2008
Last updated: 2/25/2008

The types used in the description of covariance were originally Base and Derived. Eric rightly pointed out that these take more thought to understand than concrete examples. He tends to use Animal, Giraffe and Turtle - an idea which I copied, partly as a small homage. Unfortunately I had to turn Giraffe into Cat for the sake of getting everything onto the page appropriately - but then again, it's not every day one turns giraffes into cats! Mads Torgersen apparently uses Fruit, Apple and Banana.

Feel free to consider using Person, LanguageGeek and SaneDeveloper if you wish...