Powerful_Python.pdf
(
3400 KB
)
Pobierz
Powerful
Python
Patterns and Strategies with Modern Python
Aaron Maxwell
“The concepts taught in
Powerful Python
are essential for anyone who takes
their Python skills seriously, and the relatable prose and clear examples
make it as simple as possible for the reader to learn those concepts.”
Rodrigo Girão Serrão
Author of mathspp.com
Powerful Python
How do you become proficient at writing complex, powerful
Python applications—without wasting time rehashing the
basics you already know or getting bogged down in features
that just don’t matter? In this unique book, author Aaron
Maxwell focuses on the Python first principles that act
to accelerate everything else: the 5% of programming
knowledge that makes the remaining 95% fall like dominos.
You’ll learn:
Aaron Maxwell
is a software
engineer and Pythonista. Through
a decade working in Silicon Valley
engineering teams, he gained
production experience in backend
engineering at scale, data science and
machine learning, test automation
infrastructure, DevOps and SRE,
cloud infrastructure, marketing
automation, and coding in a variety
of languages. He’s taught advanced
Python to over 10,000 technology
professionals worldwide.
•
Higher-order function abstractions to create powerful,
expressive code
•
How to make all your Python code more robust and
scalable with generator design patterns
•
Cognitive benefits of Pythonic comprehensions, how to
build more complex comprehension structures, and their
surprising link with generators
•
Metaprogramming with decorators, for potent
abstractions and code reuse patterns that cannot be
captured any other way
•
Python’s exception model for “out of band” signaling
of errors and other events
•
Advanced object-oriented programming techniques
within Python’s object model
•
How to leverage test-driven development to write better
software faster and get into “flow” coding states
•
Effective module organization, basic and advanced Python
logging, and more
PY THON / PROGR AMMING
US $64.99 CAN $81.99
ISBN: 978-1-098-17570-2
Patterns and Strategies with Modern Python
Powerful Python
Aaron Maxwell
Powerful Python
by Aaron Maxwell
Copyright © 2025 MigrateUp LLC. 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://oreilly.com). For more information, contact our corporate/institutional
sales department: 800-998-9938 or
corporate@oreilly.com.
Acquisitions Editor:
Brian Guerin
Development Editor:
Virginia Wilson
Production Editor:
Aleeya Rahman
Copyeditor:
Helena Stirling
Proofreader:
Krsta Technology Solutions
November 2024:
First Edition
Indexer:
Ellen Troutman-Zaig
Interior Designer:
David Futato
Cover Designer:
Karen Montgomery
Illustrator:
Kate Dullea
Revision History for the First Edition
2024-11-08:
First Release
See
http://oreilly.com/catalog/errata.csp?isbn=9781098175702
for release details.
Powerful Python
is a trademark of MigrateUp LLC. All rights reserved. The O’Reilly logo is a registered
trademark of O’Reilly Media, Inc.
Powerful Python,
the cover image, and related trade dress are trade‐
marks of O’Reilly Media, Inc.
The views expressed in this work are those of the author and do not represent the publisher’s views. 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 limitation 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 responsibility to ensure that your use thereof complies
with such licenses and/or rights.
978-1-098-17570-2
[LSI]
Table of Contents
Preface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . vii
1.
Scaling with Generators. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1
Iteration in Python
Generator Functions
Advancing next()
Converting to a Generator Function
Do You Need Generators?
Generator Patterns and Scalable Composability
Text Lines to Dicts
Composable Interfaces
Fanning Out
Fanning In
Python Is Filled with Iterators
The Iterator Protocol
Conclusion
List Comprehensions
Formatting for Readability (and More)
Multiple Sources and Filters
Independent Clauses
Multiple Filters
Comprehensions and Generators
Dictionaries, Sets, and Tuples
Conclusion
1
4
6
7
8
9
11
12
13
14
16
17
21
24
26
27
28
29
31
34
36
2.
Creating Collections with Comprehensions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
iii
Plik z chomika:
justname
Inne pliki z tego folderu:
The_Design_of_Web_APIs_2nd_Edition.pdf
(34173 KB)
MySQL_Crash_Course.pdf
(49504 KB)
How_Computers_Really_Work.pdf
(19843 KB)
The_Road_to_React_2025-05-21.pdf
(3282 KB)
The_Road_to_React_2024-02-05.pdf
(3292 KB)
Inne foldery tego chomika:
_stuff
_temp
babes.com
bangbros.com
brattysis.com
Zgłoś jeśli
naruszono regulamin