Python 3.x: From Beginner to Practical Application cover

Python 3.x: From Beginner to Practical Application

No rating yet
Chapters
40
ISBN
9787111621232

Tags

Summary

Python 3.x: From Beginner to Practical Application, compiled by Zhao Jun and others, was published by China Machine Press in April 2019. The book runs 394 pages and is a systematic Python textbook aimed at complete beginners and university programming courses. The book unfolds in plain language and a step-by-step structure: it opens with basic concepts of programming languages, algorithms, and flowcharts, then guides readers to download and install the Anaconda package and set up a development environment with the command prompt, the Spyder editor, and the IPython command window, followed by a first hands-on session using print output and Hello World. On the syntax level, the book covers data types, variables and constants, expressions and operators, control flow structures (sequence, selection, loops, and break/continue), creating and slicing strings, character functions and methods, function definition and parameter passing, variable scope, recursive functions, selection sort and bubble sort, lambda expressions, and advanced data types such as lists, tuples, dictionaries, and sets. On the application level, the book further discusses importing modules and packages and installing third-party packages with pip, file access and processing, error and exception handling, object-oriented programming, and GUI-based window application development, extending to arrays and scientific computing, data extraction, and web scraping. Each chapter includes a key-point review, end-of-chapter exercises, and hands-on practice examples (such as a pocket-money ledger helper, a report-card statistics helper, a simple word translator, a lottery betting game program, and a program to tally high-frequency words from past English exams), with answers to the Chapter 15 exercises at the end of the book for self-study and classroom use.

Editor's review

在Python入门书扎堆的市场里,这本教材的特点是「按一门课的逻辑写书」,而不是按速查手册的逻辑罗列语法。作者赵军等从「程序设计语言—算法—流程图」讲起,先把计算思维的底子打好,再带你装Anaconda、打开Spyder写第一个Hello World,零基础读者不会一上手就卡在环境配置上。 结构上它走的是「基础语法+进阶主题+应用延伸」三段路:数据类型、运算符、流程控制、字符串、函数、列表元组字典集合逐层推进;随后进入模块与程序包、文件存取、异常处理、面向对象和GUI窗口程序,最后延伸到数组与科学计算、数据提取与网络爬虫。相比只讲语法的入门书,它的终点更接近「能做出东西」。 最值得称道的是每章都落在「上机实践演练」上:零用钱记账小管家、成绩单统计小帮手、密码验证程序、金字塔图形、简易单词翻译器、乐透投注游戏、统计历年英语考试高频词……题目小而完整,代码讲透思路,学完一章就能跑出一个能看的结果。加上每章的重点回顾与课后习题,以及书末第15章的习题参考答案,作为大专院校教材或自学路线图都相当顺手。 需要提醒的是,本书出版于2019年,环境部分以Anaconda+Spyder为主,如今更流行VS Code、PyCharm与Jupyter,读者可自行替换工具,语法主体仍是Python 3.x通用内容。

Who it's for

A good fit for

  • 完全没有编程基础、想系统学一门语言的在校学生与转行者
  • 需要一本可按章节授课、带习题与上机演练的Python课程教材的高校教师
  • 打算从其他语言转向Python,希望完整梳理语法体系的技术人员
  • 偏好「边学边练」,喜欢每章完成一个小项目来巩固的程序设计自学者

Not a good fit for

  • 已具备Python基础、想深入并发、元编程或性能优化的进阶开发者
  • 希望直接学习数据分析、机器学习或Web框架实战的读者,本书仅作入门铺垫
  • 需要针对Python 3.10及以上新特性(如模式匹配)的系统讲解的读者

Reading tips

  1. 先按第1章装好Anaconda与Spyder并跑通Hello World,环境不通不要急着往后读。
  2. 每章读完先手敲一遍书中的范例代码,再做「上机实践演练」,最后用课后习题自测,避免只看不写。
  3. 第6章递归与排序、第7章容器类型、第11章面向对象是全书三个难点,建议各留出双倍时间并整理笔记。
  4. 第9至14章可按兴趣跳跃:偏数据处理读第13、14章,偏软件开发读第11、12章,读完后用自选小项目替代书中的旧案例练手。

About the publisher

China Machine Press China · Founded in 1950

In addition to science and technology and professional publishing, the books in our catalog from China Machine Press also reflect a sustained focus on psychology, computing, management, finance and economics, and social sciences. In psychology, the catalog includes works by C. G. Jung and introductions to analytical psychology, as well as applied topics such as stress and health, and addiction and healing. In computing, it features Structure and Interpretation of Computer Programs (JavaScript Edition). Management and finance titles include Administrative Behavior (4th Edition), The Price of Inequality (Collector's Edition), and This Time Is Different: Eight Centuries of Financial Folly (Commemorative Edition). In the philosophy and history of science, there is The Worldview: The Third Edition. Relevant authors include C. G. Jung, William McGuire, Sonu Shamdasani, and Gabor Maté. Public information is limited; the above summarizes the publisher's profile based solely on the books in our catalog.

Contents

  1. Preface
  2. Chapter 1 Introduction to Python and Setting Up the Development Environment
  3. 1.1 Introduction to Python
  4. 1.2 Programming Languages and Programming (Algorithms, Flowcharts, the Programming Process)
  5. 1.3 Applications of Python (Web Development Frameworks, Digital Technology Integrated Development)
  6. 1.4 Setting Up the Python Development Environment (Downloading and Installing Anaconda)
  7. 1.5 Python Writing Tools (Command Prompt, Spyder Editor, IPython Command Window)
  8. 1.6 The print Output Statement
  9. 1.7 Python Programming Style (Encoding Declarations, Comments, Line Breaks and Joining)
  10. 1.8 Hands-On Practice: Hello World
  11. Chapter 2 Data Types, Variables, and Constants
  12. 2.1 Variable Naming and Assignment (Static vs. Dynamic Typing)
  13. 2.2 Python's Numeric Data Types (Integers, Floats, Booleans)
  14. 2.3 Constants
  15. 2.4 Formatted Input and Output (Formatted Output, input())
  16. 2.5 Data Type Conversion
  17. 2.6 Hands-On Practice: Pocket-Money Ledger Helper
  18. Chapter 3 Expressions and Operators
  19. 3.1 Arithmetic Operators
  20. 3.2 Assignment Operators
  21. 3.3 Comparison Operators
  22. 3.4 Logical Operators
  23. 3.5 Bitwise Operators
  24. 3.6 Bit-Shift Operators
  25. 3.7 Operator Precedence
  26. 3.8 Hands-On Practice: Report-Card Statistics Helper (Reading CSV Files)
  27. Chapter 4 Control Flow Structures
  28. 4.1 Understanding Control Flow (Sequence, Selection, Loop Structures)
  29. 4.2 Selection Control Flow (if…else, Multiple Selection, Nested if)
  30. 4.3 Loops (while, for, Nested Loops)
  31. 4.4 The continue and break Statements
  32. 4.5 Hands-On Practice: Build Your Own Password Verification Program
  33. Chapter 5 Working with Strings
  34. 5.1 Creating Strings
  35. 5.2 Understanding Escape Characters
  36. 5.3 Formatted Parameter Output
  37. 5.4 String Indexing and Slicing (Indexing, Slicing, split())
  38. 5.5 Common String Operators (Comparison, in and not in)
  39. 5.6 Common String Functions and Methods (len, Case Conversion, count, strip, replace, find/index, startswith/endswith)
  40. 5.7 Hands-On Practice: Extracting and Using Open Data

FAQ

这本书适合零基础完全没接触过编程的人吗?
适合。全书从程序设计语言、算法与流程图等基础概念讲起,第1章即手把手带读者安装Anaconda与Spyder并完成Hello World,所有语法点都配有范例,被多所高校图书馆列为程序设计课程教材参考。
书中的Python版本和开发环境过时了吗?
语法内容基于Python 3.x,主体至今通用;但书中以Anaconda+Spyder+IPython命令窗口为主线,出版于2019年。读者可继续使用Anaconda,也可改用VS Code或PyCharm,按第1章的思路配置即可,不影响后续学习。
这本书和《Python编程:从入门到实践》有什么区别?
《Python编程:从入门到实践》以游戏、数据可视化、Django三大项目收尾;本书更接近课堂教学结构,每章有重点回顾、课后习题和第15章习题参考答案,应用方向落在模块与包、文件、异常、面向对象、GUI、科学计算与网络爬虫上。
书末第15章是什么内容?
第15章为「课后习题参考答案」,集中给出前14章各章课后习题的解答,方便自学者对照检查,也是本书区别于同类入门书的一个实用设计。
这本书能用来准备计算机等级考试或课堂学习吗?
作为教材型读物比较合适:章节划分清晰、每章有重点回顾与习题、配套上机演练,多数图书馆将其归入TP311.561(Python程序设计)类目,适合课程学习;但若针对特定考试大纲,仍建议对照官方考纲补充练习。

Comments

Find this book

This site is an index: you start “Search all sources” in your browser, and the entries it lists all point to third-party sites; please judge their availability yourself.

About the author

赵军 Author

Zhao Jun is an author whose works span a notably wide range of subjects. Public information about him is limited, and his nationality, dates of birth and death, and educational background are not clearly recorded. Judging from the four works held in the collection, his writing crosses history, politics, programming and design, and the social sciences. In history, he focuses on Sino-Japanese relations and modern Chinese politics, having written on Japanese "continental adventurers" and the war of aggression against China, as well as a study of the Zunyi Conference, which reflects his interest in modern Chinese history and the sources of the War of Resistance. On the technical side, he has written an introduction to Python for medical data analysis and a study of spatial information development and models, showing an engagement with programming practice and information science. This parallel path of humanities and technology gives his works both a documentary and an applied orientation, useful to readers in the relevant fields.

More by the same author

Top rated in the same category