没有合适的资源?快使用搜索试试~ 我知道了~
首页数据结构与程序设计(英文版)Data Structures and Program Design in C++ Robert L. Kruse
资源详情
资源评论
资源推荐
Data Structures
and
Program Design
in C
++
NAVIGATING THE DISK
ForinformationonusingtheAcrobattoolbarandotherAcrobatcommands,consult
the Help document within Acrobat. See especially the section “Navigating Pages.”
Material displayed in green enables jumps to other locations in the book, to
transparency masters, and to run sample demonstration programs. These come in
three varieties:
➥ The green menu boxes in the left margin of each page perform jumps to fre-
quently used parts of the book:
➥ Green material in the text itself will jump to the place indicated. After taking
such a jump, you may return by selecting the
// icon (go back) in the Acrobat
toolbar.
➥ The transparency-projector icon ( ) brings up a transparency master on the
current topic. Return by selecting the
// icon (go back) in the Acrobat toolbar.
➥ The Windows ( ) icon in the left margin select and run a demonstration pro-
gram, which will operate only on the Windows platform.
This CD contains a folder
textprog that contains the source code for all programs
and program segments appearing in the book. These files cannot be compiled
directly, but they can be copied and used for writing other programs.
HINTS FOR PAGE NAVIGATION
➥ Each chapter (or other major section) of the book is in a separate pdf file, so
you may start Acrobat directly on a desired chapter.
➥ To find a particular section in the current chapter, hit the Home key, or select
|/ in the Acrobat toolbar or in the green menu bar, which will jump to the
first page of the chapter where there is a table of contents for the chapter.
➥ After jumping to a new location in the book, you can easily return to your
previous location by selecting
// (go back) in the Acrobat toolbar.
➥ To find a particular topic, select the index icon ( ) in the left margin.
➥ To find a particular word in the current chapter, use the binoculars icon in the
Acrobat toolbar.
➥ The PgDown and Enter (or Return) keys advance one screenful, whereas ., ↓,
→, and advance one page. Of these, only will move from the last page of
one chapter to the first page of the next chapter.
➥ To move backwards, PgUp and Shift+Enter move up one screenful, whereas
/, ↑, ←, and move back one page. Of these, only will move from the first
page of one chapter to the last page of the previous chapter.
Data Structures
and
Program Design
in C
++
Robert L. Kruse
Alexander J. Ryba
CD-ROM prepared by
Paul A. Mailhot
Prentice Hall
Upper Saddle River, New Jersey 07458
Library of Congress Cataloging–in–Publication Data
KRUSE,ROBERT L.
Data structures and program design in C++ / Robert L. Kruse,
Alexander J. Ryba.
p. cm.
Includes bibliographical references and index.
ISBN 0–13–087697–6
1. C++ (Computer program language) 2. Data Structures
(Computer Science) I. Ryba, Alexander J. II. Title.
QA76.73.C153K79 1998 98–35979
005.13’3—dc21 CIP
Publisher: Alan Apt
Editor in Chief: Marcia Horton
Acquisitions Editor: Laura Steele
Production Editor: Rose Kernan
Managing Editor: Eileen Clark
Art Director: Heather Scott
Assistant to Art Director: John Christiana
Copy Editor: Patricia Daly
Cover Designer: Heather Scott
Manufacturing Buyer: Pat Brown
Assistant Vice President of Production and
Manufacturing:
David W. Riccardi
Editorial Assistant: Kate Kaibni
Interior Design: Robert L. Kruse
Page Layout: Ginnie Masterson (PreT
E
X, Inc.)
Art Production: Blake MacLean (PreT
E
X, Inc.)
Cover art: Orange, 1923, by Wassily Kandinsky (1866-1944), Lithograph in Colors. Source: Christie’s Images
© 2000 by Prentice-Hall, Inc.
Simon & Schuster/A Viacom Company
Upper Saddle River, New Jersey 07458
The typesetting for this book was done with PreT
E
X, a preprocessor and macro package for the T
E
X typesetting system
and the P
OSTSCRIPT page-description language. PreT
E
X is a trademark of PreT
E
X, Inc.; T
E
X is a trademark of the American
Mathematical Society; P
OSTSCRIPT is a registered trademarks of Adobe Systems, Inc.
The authors and publisher of this book have used their best efforts in preparing this book. These efforts include the re-
search, development, and testing of the theory and programs in the book to determine their effectiveness. The authors
and publisher make no warranty of any kind, expressed or implied, with regard to these programs or the documenta-
tion contained in this book. The authors and publisher shall not be liable in any event for incidental or consequential
damages in connection with, or arising out of, the furnishing, performance, or use of these programs.
All rights reserved. No part of this book may be reproduced, in any form or by any means, without permission in writ-
ing from the publisher.
Printed in the United States of America
10987654321
ISBN 0-13-087697-6
Prentice-Hall International (U.K.) Limited,
London
Prentice-Hall of Australia Pty. Limited, Sydney
Prentice-Hall Canada Inc., Toronto
Prentice-Hall Hispanoamericana, S.A., Mexico
Prentice-Hall of India Private Limited, New Delhi
Prentice-Hall of Japan, Inc., Tokyo
Simon & Schuster Asia Pte. Ltd., Singapore
Editora Prentice-Hall do Brasil, Ltda., Rio de Janeiro
Contents
Preface ix
Synopsis xii
Course Structure xiv
Supplementary Materials xv
Book Production xvi
Acknowledgments xvi
1
Programming
Principles
1
1.1 Introduction 2
1.2 The Game of Life 4
1.2.1 Rules for the Game of Life 4
1.2.2 Examples 5
1.2.3 The Solution: Classes, Objects,
and Methods 7
1.2.4 Life: The Main Program 8
1.3 Programming Style 10
1.3.1 Names 10
1.3.2 Documentation and Format 13
1.3.3 Refinement and Modularity 15
1.4 Coding, Testing,
and Further Refinement 20
1.4.1 Stubs 20
1.4.2 Definition of the Class Life 22
1.4.3 Counting Neighbors 23
1.4.4 Updating the Grid 24
1.4.5 Input and Output 25
1.4.6 Drivers 27
1.4.7 Program Tracing 28
1.4.8 Principles of Program Testing 29
1.5 Program Maintenance 34
1.5.1 Program Evaluation 34
1.5.2 Review of the Life Program 35
1.5.3 Program Revision
and Redevelopment 38
1.6 Conclusions and Preview 39
1.6.1 Software Engineering 39
1.6.2 Problem Analysis 40
1.6.3 Requirements Specification 41
1.6.4 Coding 41
Pointers and Pitfalls 45
Review Questions 46
References for Further Study 47
C++ 47
Programming Principles 47
The Game of Life 47
Software Engineering 48
2
Introduction
to Stacks
49
2.1 Stack Specifications 50
2.1.1 Lists and Arrays 50
2.1.2 Stacks 50
2.1.3 First Example: Reversing a List 51
2.1.4 Information Hiding 54
2.1.5 The Standard Template Library 55
v
剩余733页未读,继续阅读
wuzht3
- 粉丝: 7
- 资源: 6
上传资源 快速赚钱
- 我的内容管理 收起
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
会员权益专享
最新资源
- ExcelVBA中的Range和Cells用法说明.pdf
- 基于单片机的电梯控制模型设计.doc
- 主成分分析和因子分析.pptx
- 共享笔记服务系统论文.doc
- 基于数据治理体系的数据中台实践分享.pptx
- 变压器的铭牌和额定值.pptx
- 计算机网络课程设计报告--用winsock设计Ping应用程序.doc
- 高电压技术课件:第03章 液体和固体介质的电气特性.pdf
- Oracle商务智能精华介绍.pptx
- 基于单片机的输液滴速控制系统设计文档.doc
- dw考试题 5套.pdf
- 学生档案管理系统详细设计说明书.doc
- 操作系统PPT课件.pptx
- 智慧路边停车管理系统方案.pptx
- 【企业内控系列】企业内部控制之人力资源管理控制(17页).doc
- 温度传感器分类与特点.pptx
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功
评论0