|Hello World! Computer Programming for Kids and Other Beginners|
Author: Warren and Carter Sande
A motivating and well thought out approach, using Python and other free resources.
NOTE: This review relates to the first edition of this book (ISBN: 978-1933988498 from 2009).
Computer programming is a skill that all children should have the opportunity to learn. Indeed a couple of decades back I assumed that by now it would be on an equivalent footing with reading and writing on the school curriculum. Sadly my prediction hasn't materialised so I'm very pleased to discover this new book written by a father and son team to help make up for a very real deficiency in the educational system.
Learning to program is a mind expanding experience so while the book has been written to appeal to a young audience it has a lot to offer all beginners. It adopts a logical approach and presents clear explanations backed up by well chosen examples.
So that you can proceed without having to buy any software, the book uses Python as its teaching language and provides it, together with the examples used throughout the book, on its own website in versions for Windows, Mac and Linux. You are encouraged to type in at least some of the examples but having them supplied is obviously a bonus.
You might have reservations about using Python as a teaching language - but it's not a bad choice when you consider its characteristics. It's an interpreted language which means feedback is fast and problems can be corrected interactively - always good when you are learning. It is object oriented so its a modern language but you can write code without using objects so these more difficult ideas can be slotted in after the basics like flow of control and methods have been mastered. It's also named in honour of Monty Python and who can resist the temptation to remember, and reproduce the old jokes - any excuse is a good one!
The book employs a child-friendly style and is suitable for any beginner aged from 9 to 99. The language is straightforward and there are plenty of graphics that aid communication. Certain characters appear at intervals. The most important one is Carter - the book's junior co-author. He appears with questions and comments that draw attention to key points and as you get deeper into programming it's Carter who notices when things don't work as they should. There's also a bespectacled girl who appears with hints in "Thinking like a programmer" boxouts in early chapters and a youth carrying a surf board whose messages under a "Don't Worry, Be Happy" banner offer reassurance. I particularly liked the oriental-looking granny who provides information about how things were different "in the good old days" of early personal computers. Word boxes for important jargon and technical boxouts that explain what's going on at the hardware level also contribute to a varied and highly informative presentation. Self test questions (with answers) appear at the end of every chapter together with practical problems for the reader to solve - again the solutions are at the end of the book.
The book provides a well-structured course in programming. In the very first chapter, having taken you through installing Python and the IDLE editor, you get off to a flying start by running two programs. Chapter 2 is where we get down to basics starting with variables, numbers and strings; quickly proceeds to arithmetic operations; looks at types of data and then considers input. In Chapter 6 on GUIs the number guessing game from Chapter 1 is revisited and is transformed into something more sophisticated. I have some reservations about the degree of complexity encountered in the next chapter on tests for conditions and was relieved to discover that only the for loop is introduced at this stage in the following one. The idea of commenting code is introduced next and then Chapter 10 is devoted to a skiing game that uses the techniques introduced so far. I would have preferred to have the program listing interspersed with explanatory text - instead there are terse explanations annotating the listing - but, despite the encouragement to type the game in as useful exercise, I imagine many readers will use the supplied program as a shortcut that gives them more time for playing it! The game also serves as an introduction to Pygame, a Python module that crops up frequently throughout the rest of the book.
The level ramps up quickly in the following chapters which having introduced nested and variable loops, lists and functions proceed to objects in a chapter that covers attributes, methods and classes along with polymorphism and inheritance. Modules and namespaces come next and are followed by the potentially troublesome but obviously appealing topic of graphics. This opens up lots of potential for games programming and is followed by a chapter on sprites and collision detection, complete with code for controlling bouncing balls. This leads logically on to considering events in a chapter that culminates with programming PyPong, a version of the classic bat and ball game. Sound effects and music are added to the game in the next chapter which covers sound.
Chapter 20 shows how to create GUIs using PythonCard and introduces the components - buttons, text and so on - that make up a GUI. It presents a program for converting temperatures in Celsius to Fahrenheit as a example. Print formatting and strings is covered next and then comes file input and output, with a game of hangman as its example. This is followed by randomness with dice and card games and computer simulations with a lunar lander and a virtual pet to program.
This brings us to the end of the book. I was amused to read in its "What's Next" chapter the recommendation of locating 1980's titles of books of games programs written in BASIC and a reminder that QBASIC still exists. Perhaps it's time to dust the cobwebs off the many such volumes currently neglected on shelves or relegated to attics.
This book is a very good introduction to programming and can be recommended to anyone, young or old, who wants to start learning this vital and highly enjoyable skill.
|Last Updated ( Saturday, 22 December 2018 )|