Head First Python

Paul Barry

出版时间

2010-11-30

ISBN

9781449382674

评分

★★★★★
书籍介绍

Are you keen to add Python to your programming skills? Learn quickly and have some fun at the same time with Head First Python. This book takes you beyond typical how-to manuals with engaging images, puzzles, stories, and quizzes that are proven to stimulate learning and retention. You’ll not only learn how Python differs from other programming languages and how it’s similar, you’ll learn how to be a great programmer.

Understand Python’s unique method of dynamically storing data

Build Python-enabled web servers and web applications

Write mobile apps on the Android platform

Use PyGame and PyKyra to develop sophisticated games

Build GUI-based programs with Python’s handy code library

Write Python scripts to automate tasks on your favorite applications

We think your time is too valuable to waste struggling with new concepts. Using the latest research in cognitive science and learning theory to craft a multi-sensory learning experience, Head First Python uses a visually rich format designed for the way your brain works, not a text-heavy approach that puts you to sleep.

Paul Barry is formally educated and trained in Computer Science and holds a Masters Degree in Computing Science. He has been programming professionally, on and off, for close to 25 years. Paul already has two textbooks to his name, and is also a Contributing Editor to Linux Journal magazine. His day job is with the Institute of Technology, Carlow in Ireland where he has spent o...

(展开全部)

AI导读
核心看点
  • Head First系列特色,图文并茂趣味学习
  • 涵盖Python基础、Web及Android开发
  • 强调动手实践,通过项目掌握编程技能
适合谁读
  • 零基础或初级Python学习者
  • 喜欢趣味图解式教材的读者
  • 希望快速上手实战项目的编程爱好者
读前提醒
  • 本书侧重实践而非语法深究
  • 需自行补充部分技术细节
  • 注意区分Python 2与3版本差异
读者共识
  • 入门友好,内容浅显易懂
  • 实战性强,适合建立编程信心
  • 深度不足,进阶需参考其他书籍

本导读基于书籍简介、目录、原文摘录、短评和书评生成,不等同于全文精读。

精彩摘录
  • "Python 术语 - PyPI就是Python包索引(Python Package Index) - Python内存中的名字就存放在“命名空间”中 - Python的主命名空间名为 __main__ IDLE说明 - 按F5将模块的代码“加载”到IDEL shell,模块名会专门导入到IDLE的命名空间 BULLET POINTS - 模块是一个包含Python代码的文本文件 - 发布工具允许将模块转换为可共享的包 - setup.py程序提供了模块的元数据,用来构建、安装和上传打包的发布 - 使用import语句可以将模块导入到其他程序中 - Python中的各个模块提供了自己的命名空间"
  • "- 通过利用函数和递归,可以处理代码中存在的复杂性问题 - 递归函数不需要任何改变就可以正确地处理处理任意深度的嵌套列表"
  • "Python术语 - “异常”(exception)因运行时错误而出现,会产生一个traceback - traceback是出现运行时错误的一个详细描述 BULLET POINTS - 使用open() BIF打开一个磁盘文件,创建一个迭代器从文件读取数据,一次读取一个数据行 - readline() 方法从一个打开的文件读取一行数据 - seek() 方法可以用来将文件“退回”到起始位置 - close() 方法可以用来关闭一个之前打开的文件 - split() 方法可以将一个字符串分解为一个子串列表 - 数据不符合期望的格式时会出现ValueError - 数据无法正常访问时会出现IOE"
  • "Python术语 - ‘腌制’ 将数据对象保存到一个持久存储中的过程 - ‘解除腌制’ 从持久存储中恢复一个已保存的数据对象的过程 BULLET POINTS - strip() 方法可以从字符串去除不想要的空白符 - print() BIF的file参数控制将数据发送/保存到哪里 # Py2: print >> file_object, var - finally 组总会执行,而不论try/except语句中出现什么异常 # with open(...) as ...可省略finally - 向except组传入一个异常对象,并使用as关键字赋至一个标识符 # except IOError "
  • "Python术语 - ‘原地’排序,转换然后替换 #sort() - ‘复制'排序,转换然后返回 #sorted() - ’方法串链‘,从左向右读,对数据应用一组方法 - ’函数串链‘,从右向左读,对数据应用一组函数 - ’列表推导‘,在一行上制定一个转换(而不是使用迭代) - ’分片‘,从一个列表访问多个列表项 - ’集合‘,一组无序的数据项,其中不包含重复项 BULLET POINTS - sort() 方法可以在原地改变列表的顺序 - sorted() BIF通过提供复制排序可以对几乎任何数据结构排序 - 向sort()或sorted()传入reverse=True可以按降序排列数据 -"
  • "Python术语 -BIF——内置函数。 -“组(Suite)”——Python代码块,会通过缩进来指示分组。 IDLE说明 -使用shell时可以在已输入的代码之间快速切换,Alt-P表示Previous(前一个),Alt-N表示Next(下一个)。 BULLET POINTS -列表就像数组。 -列表可以存放任意数据,而且数据可以使混合类型。列表还可以嵌套。 -len() BIF会提供某个数据对象的长度,或者统计一个集合中的项数。 -isinstance() BIF会检查一个标示符是否指示某个指定类型的数据对象。 -for循环在迭代处理上通常比一个等价的while循环更方便。 -用if··"
  • "Python术语 -”“”为多行注释,#为单行注释。 -Python内存中的名字就存放在“命名空间”中。 -Python的主命名空间为__main__。 IDLE说明 -无 BULLET POINTS -模块是一个包含Python代码的文本文档。 -使用发布工具包可将模块转换为可共享的包。 -setup.py程序提供了模块的元数据,用来构建、安装和上传打包的发布。 -使用import语句将模块导入到其他程序中。 -Python中各个模块提供了自己的命名空间,使用module.function()形式调用模块的函数时,要用命名空间限定函数。 -使用import语句的from module imp"
作者简介
Paul Barry is formally educated and trained in Computer Science and holds a Masters Degree in Computing Science. He has been programming professionally, on and off, for close to 25 years. Paul already has two textbooks to his name, and is also a Contributing Editor to Linux Journal magazine. His day job is with the Institute of Technology, Carlow in Ireland where he has spent over a decade preparing Ireland’s next generation of computing folk to be productive in the workforce. His role as a third level educator affords him the opportunity to explore, learn and teach the very latest programming technologies and practices, which is something that he enjoys even though he knows this makes him a bonafide “geek”. Paul lives just outside the town of Carlow in Ireland with his wife, two sons, daughter, dog and cat. There’s a bunch of computers and a growing collection of music instruments in the house, too (and like a lot of the Head First family, Paul is a struggling guitarist trapped inside a geek’s body). He has so far resisted any suggestion that the family acquire a hamster … or a set of drums.
用户评论
比较浅显
至少我真的对这个系列挺有好感的,像幼儿园老师那样手把手带你入门(换言之只要有幼儿园小朋友智商的自信就可以着手开始学了),数据类型那章很清楚很扎实,后来我一直再回顾这里做的笔记2333
有书评
看得好欢乐~~~~~~~~然看完就都忘了/_\
Python入门不错的好书。使用实例引人深入。2015年1月9日
补这些年的阅读书籍的数据。入门真的还是不错的,配合电脑搜索和微信里的练习群一起
我也不知道我为什么会看这本书,两年前断断续续翻完了,英文版的反而比中文的更容易理解。
不算是编程零基础入门书,翻译蹩脚
粗翻了几章 比较浅显,笼统~ HF的书还是形式大于内容 概念和策划大于理论和实用~ 不过读得下去也算是加分点吧~
收藏