书中练习的源代码和勘误表_Python编程:从入门到实践书评-查字典图书网
查字典图书网
当前位置: 查字典 > 图书网 > 编程 > Python编程:从入门到实践 > 书中练习的源代码和勘误表
HewaiNZY Python编程:从入门到实践 的书评 发表时间:2016-12-05 20:12:39

书中练习的源代码和勘误表

花了一些时间看了一下这本书,感觉python真是个极好入门的语言。本书的讲解很到位,不过就是在对一些简单知识点的讲解方面投入了过多的笔墨,太啰嗦了。

书中练习的源代码下载地址:
https://ehmatthes.github.io/pcc/

这是英文版的勘误表【网站:https://www.nostarch.com/pythoncrashcourse】:
Page 100: The line that reads:

alien_0['speed'] = fast

Should instead read:

alien_0['speed'] = 'fast'

Page 175: The line that reads:

def ElectricCar(Car):

Should instead read:

class ElectricCar(Car):

And the line that reads:

def fill_gas_tank():

Should instead read:

def fill_gas_tank(self):

Page 180: In car.py, the line that reads:

def __init__(self, battery_size=60):

Should instead read:

def __init__(self, battery_size=70):

Page 207: In "Try It Yourself" 10-6, TypeError should be ValueError.

Page 223: In the listing survey.py, in the definition marked with a (2), the line that reads:

print(question)

Should instead read:

print(self.question)

And in the definition marked with a (4), the line that reads:

for response in responses:

Should instead read:

for response in self.responses:

Page 227: The paragraph that begins "The method setUp()..." that ends with:

...and test_store_single_response() verifies that all three responses in self.responses can be stored correctly.

Should instead end with:

...and test_store_three_responses() verifies that all three responses in self.responses can be stored correctly.

Page 288: In game_stats.py, the line that reads:

def __init__(self, settings):

Should instead read:

def __init__(self, ai_settings):

Pages 429 and 453: The line that reads:

form = TopicForm(request.POST)

Should instead read:

form = TopicForm(data=request.POST)

You'll find more updates at the author's website here

展开全文


推荐文章

猜你喜欢

附近的人在看

推荐阅读

拓展阅读

对“书中练习的源代码和勘误表”的回应

eli 2017-04-18 19:56:58

对应中文版错误页码:
-----------------------------------------------------
85 alien_0['speed'] = fast -----> alien_0['speed'] = 'fast'
150 def ElectricCar(Car): -----> class ElectricCar(Car):
150 def fill_gas_tank(): -----> def fill_gas_tank(self):
155 def __init__(self, battery_size=60): -----> def __init__(self, battery_size=70):
179 TypeError -----> ValueError.
194 print(question) -----> print(self.question)
194 print(question) -----> for response in self.responses:
198 对应英文版227页已经改过来
255 def __init__(self, settings): -----> def __init__(self, ai_settings):
384 form = TopicForm(request.POST) -----> form = TopicForm(data=request.POST)
407 form = TopicForm(request.POST) -----> form = TopicForm(data=request.POST)

从小爱科学 2017-03-20 22:44:59

感谢。出版社网站没有,我试试找找英文扫描版的吧。

HewaiNZY 2017-03-20 21:16:30

没找过,你可以到出版社的官网找找

从小爱科学 2017-03-20 21:09:37

请问楼主,中文版中没有英文页码对应,是否有中文版的勘误页码?