Recently, I have been reading the book “How to think like a Computer Scientist - Learning with Python“. Its a ebook published under GNU Free Documentation License and one can grab it here. This book, it seems, was based on a book written for teaching Java (!!! God knows how and why
). Python seems a better fit here as the author himself quotes in preface as follows.
Python greatly simplifies programming examples and makes important programming ideas easier to teach. The first example from the text illustrates this point. It is the traditional “hello,world” program, which in the C++ version of the book looks like this:
#include
void main()
{
cout << "Hello, world." << endl;
}
in the Python version it becomes:
print “Hello, World!”
Yet another point which the author makes which impressed me is the following..
There are thirteen paragraphs of explanation of “Hello, world!” in the C++ version; in the Python version, there are only two. More importantly, the missing eleven paragraphs do not deal with the “big ideas” in computer programming but with the minutia of C++ syntax. I found this same thing happening throughout the book. Whole paragraphs simply disappear from the Python version of the text because Python’s much clearer syntax renders them unnecessary.
Hence one can concentrate more on “programming concepts” rather that worrying too much on language syntax and confusing the students mind. Eventually the student will also learn to choose the language best suited for his work and learning a new language will not be difficult any longer as his programming concepts foundation is pretty strong. This methodology, if incorporated in our education system, will do wonders and India will soon erase its image as Software Consumers and create the image of “Creators of future products”. We will not rely any longer on “outsourced” jobs. We shall have our own markets.
This book begins with a simple “hello world” program and goes till explaining a few data structure concepts. A few algorithms are also discussed en-route. To cut things short - Just Amazing! Must read. Hats off to the author.