C# in Depth

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

Curious change in picture

Chapter 8: Cutting fluff with a smart compiler: P225, figure 8.3

Created: 3/3/2009
Last updated: 8/15/2010
Severity: Typo

In the published version of the book, the code in the foreach loop in figure 8.3 looks like this:

foreach (var person in family)
{
    totleAge += person.Age;
}

Note the typo - totle instead of total. The really odd thing is, I don't know how that mistake came about. Every copy of the image that I can find has the correct variable name. In particular, it would have had a red squiggle underneath it in its current form. Very strange. Anyway, here's what it should look like:

Fixed figure 8.3