圖書描述
For courses in Python Programming
Introduces Python programming with an emphasis on problem-solving
Now in its Third Edition, Practice of Computing Using Python continues to introduce both majors and non-majors taking CS1 courses to computational thinking using Python, with a strong emphasis on problem solving through computer science. The authors have chosen Python for its simplicity, powerful built-in data structures, advanced control constructs, and practicality. The text is built from the ground up for Python programming, rather than having been translated from Java or C++.
Focusing on data manipulation and analysis as a theme, the text allows students to work on real problems using Internet-sourced or self-generated data sets that represent their own work and interests. The authors also emphasize program development and provide both majors and non-majors with a practical foundation in programming that will be useful in their respective fields. Among other changes, the Third Edition incorporates a switch to the Anaconda distribution, the SPYDER IDE, and a focus on debugging and GUIs.
MyProgrammingLabot included. Students, if MyProgrammingLab is a recommended/mandatory component of the course, please ask your instructor for the correct ISBN and course ID. MyProgrammingLab should only be purchased when required by an instructor. Instructors, contact your Pearson representative for more information.
MyProgrammingLab is an online learning system designed to engage students and improve results. MyProgrammingLab consists of a set of programming exercises correlated to specific Pearson CS1/Intro to Programming textbooks. Through practice exercises and immediate, personalized feedback, MyProgrammingLab improves the programming competence of beginning students who often struggle with the basic concepts of programming languages.
本書特色
About the Book
●NEW! A switch to Anaconda distribution, made freely available from Continuum Analytics, includes more than 100 pre-installed modules, removing the need for package installation.
●NEW! Fully adopted SPYDER Integrated Development Environment as a default method for editing and debugging code in the text. A truly modern IDE, Spyder has the advantages of including an integrated editor, associated interactive console, integrated debugging, integrated variable explorer, and integrated documentation viewer. Chapter 1 has been rewritten to incorporate the SPYDER IDE.
●NEW! Anaconda also includes the iPython console, a more capable console, with features including:
○An interactive history list
○Help on functions and variables using the “?” syntax
○Command line completion
●UPDATED! iPython console incorporated in every session with its features sprinkled throughout the text.
●NEW! “What’s wrong with my code” element has been added to several chapters to address the challenge of debugging.
●UPDATED! “Visual Vignettes” have been updated and simplified.
●NEW! Simple GUI development is included in several chapters, as well as a new appendix on web-based GUIs in response to student interest.
●NEW! 80 new end-of-chapter exercises are included.
●UPDATED! Chapter 16 provides discussion about Python Numbers and the various representations that are available.
●REVISED! Chapter 5 has been rewritten to not depend on Chapter 4, allowing instructors to choose the order in which they introduce concepts of strings and functions.
●Problem solving and case studies are emphasized throughout the text, including in 3 optional chapters (3, 10, and 13) that use examples to show mistakes and how to recover from them.
●Real-world, gender-neutral examples and exercisesencourage students to use Python to sort, apply, graph, and convert data. Examples include poker hands, the Gettysburg Address, EPA mileage data, breast cancer classifier, speech analysis, political debates, and S&P 500 analysis.
●An “object-use-first” approach is taken, with the authors using objects and methods early, while leaving the design and implementation of objects for later in the text, once mastery of the use of objects has been achieved.
●A traditional CS1 order with some significant differences, including:
○Strings are covered early (before functions) to allow for more data manipulation early in the text.
○File I/O is covered early for the same reason as strings.
○Topics such as plotting and drawing are included throughout the text in service of the data manipulation theme.
●Incorporates data structures as early as possible, including lists and strings, which show up before they are covered in detail.
●Drawing and graphing packages are incorporated and covered in the appendices.
●Over 180 code examples illustrate piecemeal development of larger problems.
●Almost 250 interactive sessions are provided to illustrate programming and problem-solving concepts.
●Over 275 short exercises and nearly 30 longer programming projects, many with multiple parts, are included.
●24 self-check exercises are embedded within the chapters, each with 5 or more associated questions.
●Over 40 notes provide useful programming tips and are boxed for emphasis.
MyProgrammingLab™not included. Students, if MyProgrammingLab is a recommended/mandatory component of the course, please ask your instructor for the correct ISBN and course ID.
MyProgrammingLab should only be purchased when required by an instructor. Instructors, contact your Pearson representative for more information.
MyProgrammingLab is an online learning system designed to engage students and improve results. MyProgrammingLab consists of a set of programming exercises correlated to specific Pearson CS1/Intro to Programming textbooks. Through practice exercises and immediate, personalized feedback, MyProgrammingLab improves the programming competence of beginning students who often struggle with the basic concepts of programming languages.
●Interactive Practice provides first-hand programming experience in an interactive online environment.
●Error Messages for Incorrect Answers give students immediate personalized feedback. The error messages include both the feedback from the compiler and plain English interpretations of likely causes for the incorrect answer.
●Step-by-step VideoNote Tutorials enhance the programming concepts presented in your Pearson textbook by allowing students to view the entire problem-solving process outside of the classroom—when they need help the most.
●Pearson eText gives students access to their textbook anytime, anywhere. In addition to note taking, highlighting, and bookmarking, the Pearson eText offers interactive and sharing features. Rich media options let students watch lecture and example videos as they read or do their homework. Instructors can share their comments or highlights, and students can add their own, creating a tight community of learners in your class.
●The Pearson eText companion app allows existing subscribers to access their titles on an iPad or Android tablet for either online or offline viewing.
●Dynamic grading and assessment provide auto-grading of student assignments, saving you time and offering students immediate learning opportunities:
●A dynamic roster tracks their performance and maintains a record of submissions.
●The color-coded gradebook gives you a quick glance of your classes' progress. Easily drill down to receive information on a single student's performance or a specific problem. Gradebook results can be exported to Excel to use with your LMS.
深入理解計算機科學核心概念與實踐:C++ 編程基礎與高級主題 作者: [此處留空,或者填寫一個虛構的資深計算機科學傢姓名,例如:艾倫·S·沃德] 齣版社: [此處留空,或者填寫一個知名的學術齣版社名稱,例如:經典技術齣版社] --- 圖書概述 本書旨在為渴望掌握當代軟件開發基石——C++ 編程語言——的讀者提供一套全麵、深入且注重實踐的教程。它不僅僅是一本語言參考手冊,更是一部係統性的計算機科學思維訓練指南。全書內容橫跨 C++ 的基礎語法、麵嚮對象範式(OOP)的核心原理,直至現代 C++(C++11/14/17/20)的先進特性,如並發編程、內存模型及模闆元編程。 我們堅信,精通一門強大的係統級語言,是理解現代計算架構、優化性能瓶頸和構建可擴展、高可靠性係統的關鍵。本書的結構設計,充分考慮瞭從初學者到有經驗的程序員的認知麯綫,力求在理論的嚴謹性與工程實踐的實用性之間取得完美平衡。 第一部分:C++ 基礎與程序設計範式 本部分奠定瞭堅實的編程基礎,側重於將讀者的思維從高級腳本語言的抽象層次拉迴到對硬件資源的直接控製和理解上。 第 1 章:C++ 環境搭建與編譯模型 深入探討 C++ 代碼如何從源代碼轉化為可執行文件。我們將詳細解析預處理、編譯、匯編和鏈接這四個階段的工作流程。不同編譯器的(如 GCC, Clang, MSVC)特性對比,以及如何有效利用編譯標誌進行優化和調試。理解“一次聲明,多處使用”的編譯模型對於大型項目的維護至關重要。 第 2 章:基本語法、數據類型與控製流 覆蓋 C++ 的基本數據類型(包括內置類型和用戶定義類型),強調它們在內存中的布局和大小。深入講解變量的聲明、作用域、生命周期,以及復閤數據結構如數組和結構體。控製流部分,除瞭標準的 if/else 和循環結構,還將引入基於範圍的 for 循環和 `switch` 語句的高級用法。 第 3 章:函數、內存管理與指針的藝術 函數是 C++ 的核心構建塊。本章詳細講解函數的重載、默認參數和內聯機製。重點突破內存模型:棧(Stack)與堆(Heap)的差異,以及原始指針(Raw Pointers)的聲明、解引用和算術運算。我們將嚴肅討論野指針、懸空指針等常見陷阱,並引入 `sizeof` 運算符在類型大小確定中的作用。 第 4 章:麵嚮對象編程(OOP)基石 C++ 之所以強大,在於其對麵嚮對象範式的支持。本章聚焦於三大支柱:封裝(Encapsulation)、繼承(Inheritance)和多態(Polymorphism)。詳細講解 `class` 與 `struct` 的細微差彆,構造函數(包括拷貝構造函數和移動構造函數,為後續智能指針做鋪墊)和析構函數的執行順序。多態的實現機製,特彆是虛函數錶(v-table)的內部工作原理將被剖析。 第二部分:抽象、資源管理與泛型編程 本部分將讀者帶入 C++ 抽象能力的深層,探討如何通過模闆實現代碼的復用,以及如何安全地管理程序生命周期中的資源。 第 5 章:高級類特性與“五/零法則” 深入探討運算符重載,包括流操作符(`<<` 和 `>>`)和算術運算符的自定義。重點解析拷貝控製:深拷貝與淺拷貝的界限。C++11 引入的移動語義(Move Semantics)將作為核心內容,解釋右值引用(rvalue reference)如何提升性能,並詳細闡述“析構函數、拷貝構造函數、拷貝賦值運算符、移動構造函數、移動賦值運算符”的五大特殊成員函數與“零法則”或“三/五法則”的現代實踐。 第 6 章:C++ 標準庫(STL)核心組件 STL 是 C++ 效率的保證。本章介紹 STL 的三大組件:容器(如 `vector`, `map`, `set` 的內部實現機製,並對比其時間復雜度),迭代器(Iterator 抽象層級,以及不同迭代器的特性),和算法(如 `std::sort`, `std::find` 等,並強調函數式編程風格)。特彆關注 `std::string` 的高效處理。 第 7 章:異常處理與錯誤報告 掌握結構化異常處理機製(`try-catch-throw`)。討論異常安全性的重要性,包括強異常安全、弱異常安全和基本異常安全的概念。如何編寫不會泄露資源的異常安全代碼,以及何時應使用錯誤碼而非異常。 第 8 章:模闆元編程與泛型編程 模闆是 C++ 抽象的巔峰。本章區分函數模闆和類模闆。深入解析模闆實例化過程、名稱查找規則(Name Lookup),以及模闆特化(Explicit Specialization)的應用場景。引入概念模闆(Concepts,C++20)作為約束模闆參數的強大工具,以提高編譯時錯誤檢查的清晰度。 第三部分:現代 C++ 與係統級編程 本部分聚焦於 C++11 及後續版本帶來的範式轉變,以及如何利用這些特性編寫高性能、內存安全的代碼。 第 9 章:智能指針與資源獲取即初始化(RAII) RAII 原則是現代 C++ 內存管理的核心。詳細介紹 `std::unique_ptr`(獨占所有權)、`std::shared_ptr`(共享所有權)和 `std::weak_ptr`(解決循環引用)。講解循環引用導緻的內存泄漏問題,以及智能指針如何在構造和析構函數中自動管理動態內存,徹底取代 `new` 和 `delete` 的手動調用。 第 10 章:並發編程與多綫程 隨著多核處理器的普及,並發編程至關重要。本章介紹 `std::thread` 的使用、綫程的同步機製:互斥鎖 (`std::mutex`)、條件變量 (`std::condition_variable`) 和原子操作 (`std::atomic`)。深入探討數據競爭(Data Races)的成因和預防,以及並發編程中的死鎖問題排查。 第 11 章:內存模型與 Volatile 關鍵字 理解 C++ 內存模型(Memory Model)是編寫跨平颱並發代碼的基礎。本章解釋加載(Load)、存儲(Store)操作的順序性保證。對比 C 語言的 `volatile` 關鍵字和 C++ 內存模型中的順序性概念,強調在現代多綫程環境中,僅使用 `volatile` 是不足以保證同步的。 第 12 章:高級 I/O 流與文件操作 超越基礎的 `std::cout`。講解 `std::fstream` 係列類及其工作模式(文本/二進製)。深入研究流的狀態標誌、格式化輸齣(如精度、進製控製),以及使用 C++20 的 Ranges 庫處理流數據的優雅方式。 目標讀者 學習過 C 或其他麵嚮對象語言(如 Java/C),希望深入底層、掌握係統級編程的開發者。 需要構建高性能計算(HPC)、遊戲引擎、實時係統或底層庫的工程師。 希望係統性地從 C++98 過渡到 C++20 現代語法的專業人士。 本書特色 1. 實踐導嚮的示例: 每個核心概念後都附帶一個小型、可編譯的項目示例,展示該特性的實際應用。 2. 性能洞察: 持續穿插關於編譯期優化、運行時開銷分析的討論,幫助讀者寫齣“快”的代碼。 3. 避免“C with Classes”: 嚴格遵循現代 C++ 的設計哲學,強調資源安全和抽象錶達力,摒棄過時的 C 風格編程習慣。 通過對本書內容的係統學習,讀者將不僅能熟練使用 C++ 語言本身,更能建立起一套紮實的、麵嚮性能與可維護性的軟件架構思維。