Theis | Getting Started with Python | Buch | 978-1-4932-2586-6 | sack.de

Buch, Englisch, 437 Seiten, Format (B × H): 176 mm x 252 mm, Gewicht: 768 g

Theis

Getting Started with Python


1. Auflage 2024
ISBN: 978-1-4932-2586-6
Verlag: Rheinwerk Verlag GmbH

Buch, Englisch, 437 Seiten, Format (B × H): 176 mm x 252 mm, Gewicht: 768 g

ISBN: 978-1-4932-2586-6
Verlag: Rheinwerk Verlag GmbH


If you want to program with Python, you’ve come to the right place! Take your first steps with this Python crash course that teaches you to use core language elements, from variables to branches to loops. Follow expert guidance to work with data types, functions, and modules—and learn how to manage errors and exceptions along the way. Apply Python programming to develop databases, graphical user interfaces, widgets, and more. Practice your skills with example exercises, and start developing your own applications with Python today!

In this book, you’ll learn about:

a. Language Basics
Learn the Python fundamentals, from initial installation to running your first program. Master core concepts including variables, branching, loops, functions, and modules; then work with data types such as integers, strings, and tuples.

b. Python in Practice
Apply Python programming in key development scenarios. Use Python for object-oriented programming, create and identify threads, manage files and directories, develop databases with SQLite and MySQL, and more.

c. Example Exercises
Get hands-on experience with practical programming exercises. Follow along with a game development example as you move from chapter to chapter. You’ll be ready to create your own applications with Python in no time!

Highlights include:
1) Installation
2) Python language basics
3) Object-oriented programming
4) Error handling
5) Data types
6) Multithreading
7) File processing
8) Databases
10) GUI programming
11) PyQt
12) Example exercises

Theis Getting Started with Python jetzt bestellen!

Autoren/Hrsg.


Weitere Infos & Material


... Materials for This Book ... 19

1 ... Introduction ... 21

1.1 ... Advantages of Python ... 21

1.2 ... Prevalence of Python ... 22

1.3 ... Structure of This Book ... 22

1.4 ... Exercises ... 23

1.5 ... Installation on Windows ... 23

1.6 ... Installation on Ubuntu Linux ... 24

1.7 ... Installation on macOS ... 25

2 ... Getting Started ... 27

2.1 ... Python as a Calculator ... 27

2.2 ... Our First Program ... 31

2.3 ... Saving and Running ... 32

3 ... Programming Course ... 37

3.1 ... Programming a Game ... 37

3.2 ... Variables and Operators ... 38

3.3 ... Branches ... 44

3.4 ... Loops ... 57

3.5 ... Developing a Program ... 69

3.6 ... Errors and Exceptions ... 69

3.7 ... Functions and Modules ... 74

3.8 ... Type Hints ... 80

3.9 ... The Finished Game ... 84

4 ... Data Types ... 89

4.1 ... Numbers ... 89

4.2 ... Character Strings ... 106

4.3 ... Lists ... 115

4.4 ... Tuples ... 122

4.5 ... Dictionaries ... 124

4.6 ... Sets ... 127

4.7 ... Truth Values and Nothing ... 130

4.8 ... Reference, Identity, and Copy ... 133

4.9 ... Type Hints ... 136

5 ... Advanced Programming ... 139

5.1 ... General Remarks ... 139

5.2 ... Output and Formatting ... 143

5.3 ... Functions for Iterables ... 147

5.4 ... Encryption ... 151

5.5 ... Errors and Exceptions ... 153

5.6 ... Functions ... 160

5.7 ... Built-In Functions ... 169

5.8 ... Other Mathematical Modules ... 173

5.9 ... Custom Modules ... 186

5.10 ... Command Line Parameters ... 188

5.11 ... “Fractions Training” Program ... 189

6 ... Object-Oriented Programming ... 195

6.1 ... Basic Principles ... 195

6.2 ... Advanced Topics ... 209

7 ... Various Modules ... 219

7.1 ... Date and Time ... 219

7.2 ... Queues ... 231

7.3 ... Multithreading ... 236

7.4 ... Regular Expressions ... 241

7.5 ... Audio Output ... 246

8 ... Files ... 247

8.1 ... Opening and Closing a File ... 247

8.2 ... Text Files ... 248

8.3 ... Files with a Defined Structure ... 255

8.4 ... Serialization Using pickle ... 258

8.5 ... Data Exchange Using JSON ... 261

8.6 ... Editing Multiple Files ... 264

8.7 ... Information about Files ... 266

8.8 ... Managing Files and Directories ... 266

8.9 ... The Morse Code Sample Project ... 268

8.10 ... Our Game: Version with Highscore File ... 271

8.11 ... Our Game: Object-Oriented Version with Highscore File ... 276

9 ... Databases ... 281

9.1 ... Structure of Databases ... 281

9.2 ... SQLite ... 282

9.3 ... MySQL ... 295

9.4 ... Our Game: Version with Highscore Database ... 299

9.5 ... Our Game: Object-Oriented Version with Highscore Database ... 301

10 ... User Interfaces ... 303

10.1 ... Introduction ... 303

10.2 ... Widget Types ... 308

10.3 ... Images and Mouse Events ... 326

10.4 ... The place Geometry Manager ... 332

10.5 ... Menus and Dialog Boxes ... 337

10.6 ... Drawings and Animations ... 346

10.7 ... Our Game: GUI Version ... 353

10.8 ... Exercise ... 358

11 ... User Interfaces with PyQt ... 361

11.1 ... Introduction ... 361

11.2 ... Widget Types ... 366

11.3 ... PyQt and SQLite ... 397

11.4 ... Exercise ... 409

... Appendices ... 411

A ... Miscellaneous Topics ... 411

B ... The Author ... 419

... Index ... 421



Ihre Fragen, Wünsche oder Anmerkungen
Vorname*
Nachname*
Ihre E-Mail-Adresse*
Kundennr.
Ihre Nachricht*
Lediglich mit * gekennzeichnete Felder sind Pflichtfelder.
Wenn Sie die im Kontaktformular eingegebenen Daten durch Klick auf den nachfolgenden Button übersenden, erklären Sie sich damit einverstanden, dass wir Ihr Angaben für die Beantwortung Ihrer Anfrage verwenden. Selbstverständlich werden Ihre Daten vertraulich behandelt und nicht an Dritte weitergegeben. Sie können der Verwendung Ihrer Daten jederzeit widersprechen. Das Datenhandling bei Sack Fachmedien erklären wir Ihnen in unserer Datenschutzerklärung.