VanderPlas - A Whirlwind Tour of Python-O'Reilly (2016).pdf

(3361 KB) Pobierz
A Whirlwind Tour of Python
Jake VanderPlas
Beijing
Boston Farnham Sebastopol
Tokyo
A Whirlwind Tour of Python
by Jake VanderPlas
Copyright © 2016 O’Reilly Media Inc. All rights reserved.
Printed in the United States of America.
Published by O’Reilly Media, Inc., 1005 Gravenstein Highway North, Sebastopol, CA
95472.
O’Reilly books may be purchased for educational, business, or sales promotional use.
Online editions are also available for most titles (http://safaribooksonline.com). For
more information, contact our corporate/institutional sales department:
800-998-9938 or
corporate@oreilly.com.
Editor:
Dawn Schanafelt
Production Editor:
Kristen Brown
Copyeditor:
Jasmine Kwityn
August 2016:
First Edition
Interior Designer:
David Futato
Cover Designer:
Karen Montgomery
Illustrator:
Rebecca Demarest
Revision History for the First Edition
2016-08-10:
First Release
The O’Reilly logo is a registered trademark of O’Reilly Media, Inc.
A Whirlwind Tour
of Python,
the cover image, and related trade dress are trademarks of O’Reilly Media,
Inc.
While the publisher and the author have used good faith efforts to ensure that the
information and instructions contained in this work are accurate, the publisher and
the author disclaim all responsibility for errors or omissions, including without limi‐
tation responsibility for damages resulting from the use of or reliance on this work.
Use of the information and instructions contained in this work is at your own risk. If
any code samples or other technology this work contains or describes is subject to
open source licenses or the intellectual property rights of others, it is your responsi‐
bility to ensure that your use thereof complies with such licenses and/or rights.
978-1-491-96465-1
[LSI]
Table of Contents
A Whirlwind Tour of Python. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Introduction
Using Code Examples
How to Run Python Code
A Quick Tour of Python Language Syntax
Basic Python Semantics: Variables and Objects
Basic Python Semantics: Operators
Built-In Types: Simple Values
Built-In Data Structures
Control Flow
Defining and Using Functions
Errors and Exceptions
Iterators
List Comprehensions
Generators
Modules and Packages
String Manipulation and Regular Expressions
A Preview of Data Science Tools
Resources for Further Learning
1
2
5
7
13
17
24
30
37
41
45
52
58
61
66
69
84
90
v
Zgłoś jeśli naruszono regulamin