Beginning Programming with Python For Dummies, 2nd Edition

Book description

The easy way to learn programming fundamentals with Python

Python is a remarkably powerful and dynamic programming language that's used in a wide variety of application domains. Some of its key distinguishing features include a very clear, readable syntax, strong introspection capabilities, intuitive object orientation, and natural expression of procedural code. Plus, Python features full modularity, supporting hierarchical packages, exception-based error handling, and modules easily written in C, C++, Java, R, or .NET languages, such as C#. In addition, Python supports a number of coding styles that include: functional, imperative, object-oriented, and procedural.

Due to its ease of use and flexibility, Python is constantly growing in popularity—and now you can wear your programming hat with pride and join the ranks of the pros with the help of this guide. Inside, expert author John Paul Mueller gives a complete step-by-step overview of all there is to know about Python. From performing common and advanced tasks, to collecting data, to interacting with package—this book covers it all!

  • Use Python to create and run your first application
  • Find out how to troubleshoot and fix errors
  • Learn to work with Anaconda and use Magic Functions
  • Benefit from completely updated and revised information since the last edition

If you've never used Python or are new to programming in general, Beginning Programming with Python For Dummies is a helpful resource that will set you up for success.

Table of contents

    1. Cover
    2. Introduction
      1. About This Book
      2. Foolish Assumptions
      3. Icons Used in This Book
      4. Beyond the Book
      5. Where to Go from Here
    3. Part 1: Getting Started with Python
      1. Chapter 1: Talking to Your Computer
        1. Understanding Why You Want to Talk to Your Computer
        2. Knowing that an Application is a Form of Communication
        3. Defining What an Application Is
        4. Understanding Why Python is So Cool
      2. Chapter 2: Getting Your Own Copy of Python
        1. Downloading the Version You Need
        2. Installing Python
        3. Accessing Python on Your Machine
        4. Testing Your Installation
      3. Chapter 3: Interacting with Python
        1. Opening the Command Line
        2. Typing a Command
        3. Using Help
        4. Closing the Command Line
      4. Chapter 4: Writing Your First Application
        1. Understanding Why IDEs Are Important
        2. Obtaining Your Copy of Anaconda
        3. Downloading the Datasets and Example Code
        4. Creating the Application
        5. Understanding the Use of Indentation
        6. Adding Comments
        7. Closing Jupyter Notebook
      5. Chapter 5: Working with Anaconda
        1. Downloading Your Code
        2. Working with Checkpoints
        3. Manipulating Cells
        4. Changing Jupyter Notebook’s Appearance
        5. Interacting with the Kernel
        6. Obtaining Help
        7. Using the Magic Functions
        8. Viewing the Running Processes
    4. Part 2: Talking the Talk
      1. Chapter 6: Storing and Modifying Information
        1. Storing Information
        2. Defining the Essential Python Data Types
        3. Working with Dates and Times
      2. Chapter 7: Managing Information
        1. Controlling How Python Views Data
        2. Working with Operators
        3. Creating and Using Functions
        4. Getting User Input
      3. Chapter 8: Making Decisions
        1. Making Simple Decisions by Using the if Statement
        2. Choosing Alternatives by Using the if…else Statement
        3. Using Nested Decision Statements
      4. Chapter 9: Performing Repetitive Tasks
        1. Processing Data Using the for Statement
        2. Processing Data by Using the while Statement
        3. Nesting Loop Statements
      5. Chapter 10: Dealing with Errors
        1. Knowing Why Python Doesn’t Understand You
        2. Considering the Sources of Errors
        3. Catching Exceptions
        4. Raising Exceptions
        5. Creating and Using Custom Exceptions
        6. Using the finally Clause
    5. Part 3: Performing Common Tasks
      1. Chapter 11: Interacting with Packages
        1. Creating Code Groupings
        2. Importing Packages
        3. Finding Packages on Disk
        4. Downloading Packages from Other Sources
        5. Viewing the Package Content
        6. Viewing Package Documentation
      2. Chapter 12: Working with Strings
        1. Understanding That Strings Are Different
        2. Creating Stings with Special Characters
        3. Selecting Individual Characters
        4. Slicing and Dicing Strings
        5. Locating a Value in a String
        6. Formatting Strings
      3. Chapter 13: Managing Lists
        1. Organizing Information in an Application
        2. Creating Lists
        3. Accessing Lists
        4. Looping through Lists
        5. Modifying Lists
        6. Searching Lists
        7. Sorting Lists
        8. Printing Lists
        9. Working with the Counter Object
      4. Chapter 14: Collecting All Sorts of Data
        1. Understanding Collections
        2. Working with Tuples
        3. Working with Dictionaries
        4. Creating Stacks Using Lists
        5. Working with queues
        6. Working with deques
      5. Chapter 15: Creating and Using Classes
        1. Understanding the Class as a Packaging Method
        2. Considering the Parts of a Class
        3. Creating a Class
        4. Using the Class in an Application
        5. Extending Classes to Make New Classes
    6. Part 4: Performing Advanced Tasks
      1. Chapter 16: Storing Data in Files
        1. Understanding How Permanent Storage Works
        2. Creating Content for Permanent Storage
        3. Creating a File
        4. Reading File Content
        5. Updating File Content
        6. Deleting a File
      2. Chapter 17: Sending an Email
        1. Understanding What Happens When You Send Email
        2. Creating the Email Message
        3. Seeing the Email Output
    7. Part 5: The Part of Tens
      1. Chapter 18: Ten Amazing Programming Resources
        1. Working with the Python Documentation Online
        2. Using the LearnPython.org Tutorial
        3. Performing Web Programming by Using Python
        4. Getting Additional Libraries
        5. Creating Applications Faster by Using an IDE
        6. Checking Your Syntax with Greater Ease
        7. Using XML to Your Advantage
        8. Getting Past the Common Python Newbie Errors
        9. Understanding Unicode
        10. Making Your Python Application Fast
      2. Chapter 19: Ten Ways to Make a Living with Python
        1. Working in QA
        2. Becoming the IT Staff for a Smaller Organization
        3. Performing Specialty Scripting for Applications
        4. Administering a Network
        5. Teaching Programming Skills
        6. Helping People Decide on Location
        7. Performing Data Mining
        8. Interacting with Embedded Systems
        9. Carrying Out Scientific Tasks
        10. Performing Real-Time Analysis of Data
      3. Chapter 20: Ten Tools That Enhance Your Python Experience
        1. Tracking Bugs with Roundup Issue Tracker
        2. Creating a Virtual Environment by Using VirtualEnv
        3. Installing Your Application by Using PyInstaller
        4. Building Developer Documentation by Using pdoc
        5. Developing Application Code by Using Komodo Edit
        6. Debugging Your Application by Using pydbgr
        7. Entering an Interactive Environment by Using IPython
        8. Testing Python Applications by Using PyUnit
        9. Tidying Your Code by Using Isort
        10. Providing Version Control by Using Mercurial
      4. Chapter 21: Ten (Plus) Libraries You Need to Know About
        1. Developing a Secure Environment by Using PyCrypto
        2. Interacting with Databases by Using SQLAlchemy
        3. Seeing the World by Using Google Maps
        4. Adding a Graphical User Interface by Using TkInter
        5. Providing a Nice Tabular Data Presentation by Using PrettyTable
        6. Enhancing Your Application with Sound by Using PyAudio
        7. Manipulating Images by Using PyQtGraph
        8. Locating Your Information by Using IRLib
        9. Creating an Interoperable Java Environment by Using JPype
        10. Accessing Local Network Resources by Using Twisted Matrix
        11. Accessing Internet Resources by Using Libraries
    8. About the Authors
    9. Connect with Dummies
    10. End User License Agreement

Product information

  • Title: Beginning Programming with Python For Dummies, 2nd Edition
  • Author(s): John Paul Mueller
  • Release date: February 2018
  • Publisher(s): For Dummies
  • ISBN: 9781119457893