Code examples and exercise solutions from Think Python by Allen Downey, published by O'Reilly Media.
git clone
this repository into a directory. You'll then be able to run programs by typing python <filename>
.
Many of these examples require a library that Allen Downey has written called Swampy. You can find that here
To use this material in a classroom setting, we recommend forking the repo and customizing the code and file names to fit your objectives. For instance, you might select PokerHand.py, title it assignment1.py, modify it for your purposes, etc. Your students can then git clone
your custom repository to get your assignments without getting any superfluous content. Note that students may be able to locate solutions to these problems in this repo :)
The book is available as both a free download and a physical book for purchase. See these and other options for getting the book here.
© Allen B. Downey unless otherwise noted in the code; provided under a GNU GPLv3 License.