SØG - mellem flere end 8 millioner bøger:
Viser: Automate the Boring Stuff with Python - Practical Programming for Total Beginners
Automate the Boring Stuff with Python
Practical Programming for Total Beginners
Al Sweigart
(2015)
Sprog: Engelsk
Detaljer om varen
- Paperback: 504 sider
- Udgiver: No Starch Press, Incorporated (Maj 2015)
- ISBN: 9781593275990
Chapter 1: Python Basics;
1.1 Entering Expressions into the Interactive Shell;
1.2 The Integer, Floating-Point, and String Data Types;
1.3 String Concatenation and Replication;
1.4 Storing Values in Variables;
1.5 Your First Program;
1.6 Dissecting Your Program;
1.7 Summary;
1.8 Practice Questions;
Chapter 2: Flow Control;
2.1 Boolean Values;
2.2 Comparison Operators;
2.3 Boolean Operators;
2.4 Mixing Boolean and Comparison Operators;
2.5 Elements of Flow Control;
2.6 Program Execution;
2.7 Flow Control Statements;
2.8 Importing Modules;
2.9 Ending a Program Early with sys.exit();
2.10 Summary;
2.11 Practice Questions;
Chapter 3: Functions;
3.1 def Statements with Parameters;
3.2 Return Values and return Statements;
3.3 The None Value;
3.4 Keyword Arguments and print();
3.5 Local and Global Scope;
3.6 The global Statement;
3.7 Exception Handling;
3.8 A Short Program: Guess the Number;
3.9 Summary;
3.10 Practice Questions;
3.11 Practice Projects;
Chapter 4: Lists;
4.1 The List Data Type;
4.2 Working with Lists;
4.3 Augmented Assignment Operators;
4.4 Methods;
4.5 Example Program: Magic 8 Ball with a List;
4.6 List-like Types: Strings and Tuples;
4.7 References;
4.8 Summary;
4.9 Practice Questions;
4.10 Practice Projects;
Chapter 5: Dictionaries and Structuring Data;
5.1 The Dictionary Data Type;
5.2 Pretty Printing;
5.3 Using Data Structures to Model Real-World Things;
5.4 Summary;
5.5 Practice Questions;
5.6 Practice Projects;
Chapter 6: Manipulating Strings;
6.1 Working with Strings;
6.2 Useful String Methods;
6.3 Project: Password Locker;
6.4 Project: Adding Bullets to Wiki Markup;
6.5 Summary;
6.6 Practice Questions;
6.7 Practice Project;Automating Tasks;
Chapter 7: Pattern Matching with Regular Expressions;
7.1 Finding Patterns of Text Without Regular Expressions;
7.2 Finding Patterns of Text with Regular Expressions;
7.3 More Pattern Matching with Regular Expressions;
7.4 Greedy and Nongreedy Matching;
7.5 The findall() Method;
7.6 Character Classes;
7.7 Making Your Own Character Classes;
7.8 The Caret and Dollar Sign Characters;
7.9 The Wildcard Character;
7.10 Review of Regex Symbols;
7.11 Case-Insensitive Matching;
7.12 Substituting Strings with the sub() Method;
7.13 Managing Complex Regexes;
7.14 Combining re.IGNORECASE, re.DOTALL, and re.VERBOSE;
7.15 Project: Phone Number and Email Address Extractor;
7.16 Summary;
7.17 Practice Questions;
7.18 Practice Projects;
Chapter 8: Reading and Writing Files;
8.1 Files and File Paths;
8.2 The os.path Module;
8.3 The File Reading/Writing Process;
8.4 Saving Variables with the shelve Module;
8.5 Saving Variables with the pprint.pformat() Function;
8.6 Project: Generating Random Quiz Files;
8.7 Project: Multiclipboard;
8.8 Summary;
8.9 Practice Questions;
8.10 Practice Projects;
Chapter 9: Organizing Files;
9.1 The shutil Module;
9.2 Walking a Directory Tree;
9.3 Compressing Files with the zipfile Module;
9.4 Project: Renaming Files with American-Style Dates to European-Style Dates;
9.5 Project: Backing Up a Folder into a ZIP File;
9.6 Summary;
9.7 Practice Questions;
9.8 Practice Projects;
Chapter 10: Debugging;
10.1 Raising Exceptions;
10.2 Getting the Traceback as a String;
10.3 Assertions;
10.4 Logging;
10.5 IDLE''s Debugger;
10.6 Summary;
10.7 Practice Questions;
10.8 Practice Project;
Chapter 11: Web Scraping;
11.1 Project: mapit.py with the webbrowser Module;
11.2 Downloading Files from the Web with the requests Module;
11.3 Saving Downloaded Files to the Hard Drive;
11.4 HTML;
11.5 Parsing HTML with the BeautifulSoup Module;
11.6 Project: "I''m Feeling Lucky" Google Search;
11.7 Project: Downloading All XKCD Comics;
11.8 Controlling the Browser with the selenium Module;
11.9 Summary;
11.10 Practice Questions;
11.11 Practice Projects;
Chapter 12: Working with Excel Spreadsheets;
12.1 Excel Documents;
12.2 Installing the openpyxl Module;
12.3 Reading Excel Documents;
12.4 Project: Reading Data from a Spreadsheet;
12.5 Writing Excel Documents;
12.6 Project: Updating a Spreadsheet;
12.7 Setting the Font Style of Cells;
12.8 Font Objects;
12.9 Formulas;
12.10 Adjusting Rows and Columns;
12.11 Charts;
12.12 Summary;
12.13 Practice Questions;
12.14 Practice Projects;
Chapter 13: Working with PDF and word Documents;
13.1 PDF Documents;
13.2 Project: Combining Select Pages from Many PDFs;
13.3 Word Documents;
13.4 Summary;
13.5 Practice Questions;
13.6 Practice Projects;
Chapter 14: Working with CSV Files and JSON Data;
14.1 The CSV Module;
14.2 Project: Removing the Header from CSV Files;
14.3 JSON and APIs;
14.4 The JSON Module;
14.5 Project: Fetching Current Weather Data;
14.6 Summary;
14.7 Practice Questions;
14.8 Practice Project;
Chapter 15: Keeping Time, Scheduling Tasks, and Launching Programs;
15.1 The time Module;
15.2 Rounding Numbers;
15.3 Project: Super Stopwatch;
15.4 The datetime Module;
15.5 Review of Python''s Time Functions;
15.6 Multithreading;
15.7 Project: Multithreaded XKCD Downloader;
15.8 Launching Other Programs from Python;
15.9 Project: Simple Countdown Program;
15.10 Summary;
15.11 Practice Questions;
15.12 Practice Projects;
Chapter 16: Sending Email and Text Messages;
16.1 SMTP;
16.2 Sending Email;
16.3 IMAP;
16.4 Retrieving and Deleting Emails with IMAP;
16.5 Project: Sending Member Dues Reminder Emails;
16.6 Sending Text Messages with Twilio;
16.7 Project: "Just Text Me" Module;
16.8 Summary;
16.9 Practice Questions;
16.10 Practice Projects;
Chapter 17: Manipulating Images;
17.1 Computer Image Fundamentals;
17.2 Manipulating Images with Pillow;
17.3 Project: Adding a Logo;
17.4 Drawing on Images;
17.5 Summary;
17.6 Practice Questions;
17.7 Practice Projects;
Chapter 18: Controlling the Keyboard and Mouse with GUI Automation;
18.1 Installing the pyautogui Module;
18.2 Staying on Track;
18.3 Controlling Mouse Movement;
18.4 Project: "Where Is the Mouse Right Now?";
18.5 Controlling Mouse Interaction;
18.6 Working with the Screen;
18.7 Project: Extending the mouseNow Program;
18.8 Image Recognition;
18.9 Controlling the Keyboard;
18.10 Review of the PyAutoGUI Functions;
18.11 Project: Automatic Form Filler;
18.12 Summary;
18.13 Practice Questions;
18.14 Practice Projects;Installing Third-Party Modules; The pip Tool; Installing Third-Party Modules;Running Programs; Shebang Line; Running Python Programs on Windows; Running Python Programs on OS X and Linux; Running Python Programs with Assertions Disabled;Answers to the Practice Questions;
Chapter 1;
Chapter 2;
Chapter 3;
Chapter 4;
Chapter 5;
Chapter 6;
Chapter 7;
Chapter 8;
Chapter 9;
Chapter 10;
Chapter 11;
Chapter 12;
Chapter 13;
Chapter 14;
Chapter 15;
Chapter 16;
Chapter 17;
Chapter 18;Resources;