Head First C# Fifth Edition

by Andrew Stellman & Jennifer Greene

Earlier this month I was lucky enough to get my hands on a complimentary copy of Head First C# Fifth Edition. There were things I expected and things that surprised me, here are my thoughts...

Front Cover

About the Review

This review will be an opinion piece from the perspective of a learner. I'm not a beginner in programming but I am new to C#. That puts me in the target audience for this book. I went into this primarily interested in GUI development. The scope of this review will be limited to the learning experience, for a more technical review you will need to look elsewhere.


Style

It's impossible to write about my experience with a Head First book without discussing the general Head First style. Books in this series tend to employ a lot of visual aids, a conversational tone, a wide variety of exercises and deliberate repetition. For a more detailed explanation you may check this page on the O'Reilly site.

Since this is a review from my perspective I will give my personal opinion. There are aspects to this teaching style that I prefer over others. For example, the conversational tone suits me fine. Do I feel I need it to remain attentive? Not really, I'm quite happy to read books written in a formal tone as well.

The redundancy is a factor I consider to be a major strength, sure it's repetition but it's explanation of the same idea in different ways. Having said that, I didn't find it helpful every time and in fact on one or two occasions I found myself skipping an (already explained) point in order not to break my train of thought.

I like the use of images to break up text. As you can see from the example page linked there is a clear structure to the page working its way from top to bottom, at the same time the reader's eye is drawn between locations. This page is a clear demonstration of the cognitive friendly approach this book aims for.

On the topic of presentation, the one thing I noticed immediately upon opening the book was the use of hand-drawn characters. Historically, the Head First series always used photographed images of people, for an example of what I'm talking about:

This is a huge improvement in my opinion and makes the pages look cleaner, less distracting and more relatable. It's worth pointing out that this update appears to be series wide as I've noticed the same in other latest edition Head First books.


Topics Covered

The book has 12 main chapters and then intertwined with them six Unity Labs. Topics covered in this book, in no particular order, include but are not limited to:

As a learner, the parts I particularly liked

The book opens with a clear and detailed walkthrough with screenshots guiding the reader on setting up their development environment. This is important because perhaps the reader has never used Visual Studio. I've read other books before that lacked detailed setup instructions, this can lead to great confusion and leave a bad initial impression.

The first project you're tasked with is an Animal Matching game.

Animal Matching Game

This is a great introduction to the book because it gives a fast demonstration of the power and flexibility of C# and XAML with just a few lines of code.

The .NET MAUI project Random Cards walks you through a structured process. The discussion around Ana's game also covers point one.

  1. Plan in advance how you intend to model your ideas into classes, possibly with the aid of a paper prototype.
  2. Write a working command line application.
  3. Complete the project by using those same classes in a GUI application. All the while reinforcing the importance of accessibility.

Random Cards

I very much like this methodology, first of all because it encourages the learner to really think about what they are doing. As a beginner, it's way too easy to want to rush in and start writing code, then later regret some of the choices that a better design would have avoided. By putting careful thought and planning into how you organise your classes and which methods you will make public you can separate the internal design of a class from its consuming code. Second, the process is incremental. It gives the learner the opportunity to start with the basics and build up as they go along. Last of all, having personally spent time working with users with accessibility needs, I am intimately familiar with the frustrations that can arise from inaccessible GUI design. Computers are used by all kinds of users around the world and it's important that beginners are encouraged to follow best practices concerning accessibility.

Each chapter ends with a Q&A style section. As the authors state, some of these questions are actual questions they've been asked by readers of past editions of the book. This is a great format for a few reasons:

Criticisms

As I mentioned in the introduction of this review, my primary interest is in GUI development and there was plenty of that present. I am less interested in game development and there was a lot of that too. Now I have to be fair in my assessment, the authors go to a lot of effort to explain their reasoning behind the game-centred focus. The lessons taught throughout the book while building the game projects are broadly applicable across programming. Nevertheless, my question is simple, would it have been possible to teach some of those same programming concepts while focusing on a wider variety of non game-centred projects?

Possible improvements

The lumberjack exercise in chapter eight has you build a console app to demonstrate the Stack and Queue ADTs. It does a sufficient job but I have to wonder whether this was a great opportunity to demonstrate the nature of the stack and queue in a more visual, .NET MAUI GUI app.


Overall thoughts

I believe Head First C# Fifth Edition is a very strong effort. It's clear to me that a lot of care and attention went into producing a complete and thorough learning experience for the reader. The emphasis on good programming practices, GUI accessibility and self learning techniques especially impressed me.

The first several chapters are gently paced and introduce fundamental concepts in C# but also programming in general. If you prefer a fast paced introduction to a language you should bear this in mind.

I've talked about the general style of Head First books and given my personal opinion but each person's experience will vary. I will say this much, if you've never tried reading a Head First book and C# piques your interest then I encourage you to give this book a go.

Further Notes:

Subscribe to this blog's RSS feed