Errata (2nd printing)

Errata for the Second Edition of The Quick Python Book will be posted here. If you discover any errors in the book, please post them to the Author Online Forum or send them via email to ddharms@yahoo.com.

Updated 2000/05/30


Page 34 top code section:

   
string.translate(x, string.maketrans{'i','o'), '\t')
should be (change "{" to "(" after maketran):
 
string.translate(x, string.maketrans('i','o'), '\t')

Page 235 middle of page:

>>> r"\the" == "\\the"
0
>>> r"the" == "\the"
1
should be:
>>> r"\the" == "\\the"
1
>>> r"the" == "\the"
0

Page 318 (see source code download):

    for item in self.items:
	if item in self.selected:
	s.append(str(Input(type=self.widgettype, name=self.name,
	    checked=1)))
    else:
	s.append(str(Input(type=self.widgettype,
	    name=self.name)))
	s.append(str(item))
	s.append(sep)
    return string.join(s[:-1], "")
should be:
    for item in self.items:
	if item in self.selected:
	    s.append(str(Input(type=self.widgettype,
			name=self.name, checked=1)))
	else:
	    s.append(str(Input(type=self.widgettype,
			name=self.name)))
	s.append(str(item))
	s.append(sep)
    return string.join(s[:-1], "")