读书笔记《Programming in C++》之一

下面是我读《Programming in C++》第一章的笔记,如果您想找一些C++编程入门的知识,或是打算初步煅炼自己读原版书的水平,那么这是最适合的,极力推荐您读一下。在这篇读书笔记中,将摘录书中的重点内容并在难懂的地方进行汉语标注,最合初学者阅读。

chapter 1     Overview of Programming and Problem Solving
Goals
·  To understand what a computer program is.
·  To be able to list the basic stages involved in writing a computer program.(能够列出,书写计算机程序涉及的基本步骤.)
·  To understand what an algorithm(算法) is.
·  To learn what a high-level programming language(高级程序设计语言) is.
·  To be able to describe what a compiler(编译程序) is and what it does.
·  To understand the compilation(编译) and execution processes.
·  To learn what the major components(组件) of a computer are and how they  work together.
·  To be able to distinguish(区分) between hardware and software.
·  To be able to choose an appropriate(适合的) problem-solving method for developing an algorithmic solution to a problem.
1.1 Overview of Programming
What Is Programming?
  Programming: Planning or scheduling(安排,明细表) the performance(执行) of a task or an event.
  Computer: A programmable device(可编程的装置) that can store, retrieve(检索), and process data(处理数据).
  Computer programming: The process(过程) of planning a sequence(序列) of steps for a computer to follow.
  Computer program: A sequence of instructions(命令) to be per-formed by a computer. 

How Do We Write a Program?
  To write a sequence of instructions for a computer to follow, we must go through a two-phase process(我们必须通过两个过程):

problem solving and implementation.
Problem-Solving Phase
  1. Analysis and specification(具体指明). Understand (define) the problem and what the solution must do.
  2. General solution (algorithm). Develop a logical sequence of steps that solves the problem.
  3. Verify. Follow the steps exactly to see if the solution really does solve the problem.
Implementation Phase(执行阶段)
  1. Concrete(具体) solution (program). Translate the algorithm into a programming language.
  2. Test. Have the computer follow the instructions. Then manually(人工的) check the results. If you find errors, analyze

the program and the algorithm to determine the source of the errors, and then make corrections(改正).
  Once a program has been written, it enters a third phase: maintenance(维护).
Maintenance Phase
  l. Use. Use the program.
  2. Maintain. Modify the program to meet changing requirements or to correct any errors that show up in using it.
  The programmer begins the programming process(程序过程) by analyzing the problem and developing a general solution called

an algorithm. They are the heart of the programming process.
  Algorithm: A step-by-step procedure(步进法) for solving a problem in a finite(有限的) amount of time.
  After developing a general solution, the programmer tests the algorithm, walking through each step mentally(内心地) or manually(手工地). If the algorithm doesn't work, the programmer repeats the problem-solving process, analyzing the problem again and coming up with(提出).

Programming in C++ for Engineering and Science By 作者: Larry Nyhoff ISBN-10 书号: 1439825343 ISBN-13 书号: 9781439825341 Edition 版本: 1 Release Finelybook 出版日期: 2012-08-03 pages 页数: (744 ) $110 Book Description to Finelybook sorting Developed from the author’s many years of teaching computing courses, Programming in C++ for Engineering and Science guides students in designing programs to solve real problems encountered in engineering and scientific applications. These problems include radioactive decay, pollution indexes, digital circuits, differential equations, Internet addresses, data analysis, simulation, quality control, electrical networks, data encryption, beam deflection, and many other areas. To make it easier for novices to develop programs, the author uses an object-centered design approach that helps students identify the objects in a problem and the operations needed; develop an algorithm for processing; implement the objects, operations, and algorithm in a program; and test, correct, and revise the program. He also revisits topics in greater detail as the text progresses. By the end of the book, students will have a solid understanding of how C++ can be used to process complex objects, including how classes can be built to model objects. contents : Content: Front Cover Contents Preface Acknowledgments About the Author Chapter 1: Introduction to Computing Chapter 2: Programming and Problem Solving- Software Engineering Chapter 3: Types in C++ Chapter 4: Getting Started with Expressions Chapter 5: Control Structures Chapter 6: Functions and Libraries Chapter 7: Using Classes Chapter 8: More Selection Control Structures Chapter 9: More Repetition Control Structures Chapter 10: Functions in Depth Chapter 11: Files and Streams Chapter 12: Arrays and the vector Class Template Chapter 13: Multidimensional Arrays and Vectors Chapter 14: Building ClassesChapter 15: Pointers and Linked Structures Chapter 16: Data Structures Answers to Test Yourself Questions Appe
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值