3333\title {Think Python}
3434\author {Allen B. Downey}
3535\newcommand {\thetitle }{Think Python: How to Think Like a Computer Scientist}
36- \newcommand {\theversion }{2nd Edition, Version 2.2.15 }
36+ \newcommand {\theversion }{2nd Edition, Version 2.2.16 }
3737\newcommand {\thedate }{}
3838
3939% these styles get translated in CSS for the HTML version
@@ -659,10 +659,6 @@ \section*{Contributor List}
659659
660660\item Russell Coleman helped me with my geometry.
661661
662- \item Wei Huang spotted several typographical errors.
663-
664- \item Karen Barber spotted the the oldest typo in the book.
665-
666662\item Nam Nguyen found a typo and pointed out that I used the Decorator
667663pattern but didn't mention it by name.
668664
@@ -681,17 +677,11 @@ \section*{Contributor List}
681677\item Giovanni Escobar Sosa sent a long list of corrections and
682678suggestions.
683679
684- \item Alix Etienne fixed one of the URLs.
685-
686- \item Kuang He found a typo.
687-
688680\item Daniel Neilson corrected an error about the order of operations.
689681
690682\item Will McGinnis pointed out that {\tt polyline} was defined
691683differently in two places.
692684
693- \item Swarup Sahoo spotted a missing semi-colon.
694-
695685\item Frank Hecker pointed out an exercise that was under-specified, and
696686some broken links.
697687
@@ -707,27 +697,14 @@ \section*{Contributor List}
707697
708698\item Martin Nordsletten found a bug in an exercise solution.
709699
710- \item Lars O.D. Christensen found a broken reference.
711-
712- \item Victor Simeone found a typo.
713-
714700\item Sven Hoexter pointed out that a variable named {\tt input}
715701shadows a build-in function.
716702
717- \item Viet Le found a typo.
718-
719703\item Stephen Gregory pointed out the problem with {\tt cmp}
720704in Python 3.
721705
722- \item Matthew Shultz let me know about a broken link.
723-
724- \item Lokesh Kumar Makani let me know about some broken links and some
725- changes in error messages.
726-
727706\item Ishwar Bhat corrected my statement of Fermat's last theorem.
728707
729- \item Brian McGhie suggested a clarification.
730-
731708\item Andrea Zanella translated the book into Italian, and sent a
732709number of corrections along the way.
733710
@@ -742,6 +719,14 @@ \section*{Contributor List}
742719
743720% ENDCONTRIB
744721
722+ In addition, people who spotted typos or made corrections include
723+ Richard Fursa, Brian McGhie, Lokesh Kumar Makani, Matthew Shultz, Viet
724+ Le, Victor Simeone, Lars O.D. Christensen, Swarup Sahoo, Alix Etienne,
725+ Kuang He, Wei Huang, and Karen Barber.
726+
727+
728+
729+
745730\end {itemize }
746731
747732\normalsize
@@ -3098,7 +3083,7 @@ \section{Encapsulation}
30983083pass it as an argument to {\tt square}:
30993084
31003085\begin {verbatim }
3101- alice = Turtle()
3086+ alice = turtle. Turtle()
31023087square(alice)
31033088\end {verbatim }
31043089%
@@ -4409,7 +4394,8 @@ \section{Exercises}
44094394\begin {exercise }
44104395
44114396Read the following function and see if you can figure out
4412- what it does. Then run it (see the examples in Chapter~\ref {turtlechap }).
4397+ what it does (see the examples in Chapter~\ref {turtlechap }). Then run it
4398+ and see if you got it right.
44134399
44144400\begin {verbatim }
44154401def draw(t, length, n):
@@ -4833,7 +4819,7 @@ \section{Boolean functions}
48334819
48344820\begin {verbatim }
48354821if is_divisible(x, y) == True:
4836- print('x is divisible by y'
4822+ print('x is divisible by y')
48374823\end {verbatim }
48384824%
48394825But the extra comparison is unnecessary.
@@ -5048,7 +5034,7 @@ \section{One more example}
50485034Translated into Python, it looks like this:
50495035
50505036\begin {verbatim }
5051- def fibonacci (n):
5037+ def fibonacci(n):
50525038 if n == 0:
50535039 return 0
50545040 elif n == 1:
@@ -5103,7 +5089,7 @@ \section{Checking types}
51035089\index {function!isinstance}
51045090
51055091\begin {verbatim }
5106- def factorial (n):
5092+ def factorial(n):
51075093 if not isinstance(n, int):
51085094 print('Factorial is only defined for integers.')
51095095 return None
0 commit comments