3 ms·
Mark Pilgrim solved this problem quite well in "Dive Into Python". He presented the working code first, at the beginning of each chapter ("diving in"). If you c
by scott_s 12y ago
Mark Pilgrim solved this problem quite well in "Dive Into Python". He presented the working code first, at the beginning of each chapter ("diving in"). If you could read and fully understand the code, then you had no need to read the rest of the chapter. If there were only small things you didn't understand, you could skim to those sections.
This philosophy is stated pretty clearly in the beginning of the book:
You know how other books go on and on about programming fundamentals and finally work up to building a complete, working program? Let's skip all that.
2.1. Diving in
Here is a complete, working Python program.
It probably makes absolutely no sense to you. Don't worry about that, because you're going to dissect it line by line. But read through it first and see what, if anything, you can make of it.
See: http://www.diveintopython.net/getting_to_know_python/index.html http://www.diveintopython.net/getting_to_know_python/index.h...