文档介绍:How to Think Like puter Scientist
Learning with Python
How to Think Like puter Scientist
Learning with Python
Allen Downey
Jeffrey Elkner
Chris Meyers
Green Tea Press
Wellesley, Massachusetts
Copyright °c 2002 Allen Downey, Jeffrey Elkner, and Chris Meyers.
Edited by Shannon Turlington and Lisa Cutler. Cover design by a Gimenez.
Printing history:
April 2002: First edition.
Green Tea Press
1 Grove St.
. Box 812901
Wellesley, MA 02482
Permission is granted to copy, distribute, and/or modify this document under the
terms of the GNU Free Documentation License, Version or any later version pub-
lished by the Free Software Foundation; with the Invariant Sections being “Foreword,”
“Preface,” and “Contributor List,” with no Front-Cover Texts, and with no Back-
Cover Texts. A copy of the license is included in the appendix entitled “GNU Free
Documentation License.”
The GNU Free Documentation License is available from by writing to
the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-
1307, USA.
A A
The original form of this book is LTEX source code. Compiling this LTEX source has
the effect of generating a device-independent representation of a textbook, which can
be converted to other formats and printed.
A
The LTEX source for this book is available from
Publisher’s Cataloging-in-Publication (provided by Quality Books, Inc.)
Downey, Allen
How to think like puter scientist : learning
with Python / Allen Downey, Jeffrey Elkner, Chris
Meyers. – 1st ed.
p. cm.
Includes index.
ISBN 0-9716775-0-6
2002100618
1. Python (Computer program language) I. Elkner,
Jeffrey. II. Meyers, Chris. III. Title
2002 ’3
QBI02-200031
Foreword
By David Beazley
As an educator, researcher, and book author, I am delighted to see -
pletion of this book. Python is a fun and extremely easy-to-use programming
language that has steadily gained in popularity over the last few years. De-