| Author |
Think Python: Is functional programming covered in your book?
|
qunfeng wang
Ranch Hand
Joined: Jan 28, 2005
Posts: 406
|
|
|
I like python due to its capability to support both functional programming and OO. I didn't find any chapter in your book covers functional programming.
|
To be or not to be. It's a question.
|
 |
Allen Downey
Author
Greenhorn
Joined: Sep 07, 2012
Posts: 25
|
|
The main thread through Think Python is from procedural programming to object-oriented programming, so I don't do a lot of functional programming.
I cover a few topics that fall under the general heading of functional programming: there are some examples that pass functions in as parameters, and lots of recursion. I present map, filter and reduce patterns, but we do it using for loops (for good reason, I think, but the style is not as functional as it could be).
Beginners often struggle with recursion, so I present it early (before iteration!) and often.
But I don't present recursive data structures in this book, and I don't think I use lambda to create anonymous functions.
So, no, functional programming is not a focus.
Allen
|
All of my books are available from http://greenteapress.com
|
 |
 |
I agree. Here's the link: jrebel
|
|
subject: Think Python: Is functional programming covered in your book?
|
|
|