<p><p></p><p></p><p>Immerse yourself in learning Python and introductory data analytics with this book’s project-based approach. Through the structure of a ten-week coding bootcamp course, you’ll learn key concepts and gain hands-on experience through weekly projects.</p><p>Each chapter in this book
Python Projects for Beginners: A Ten-Week Bootcamp Approach to Python Programming
✍ Scribed by Connor P. Milliken
- Publisher
- Apress
- Year
- 2019
- Tongue
- English
- Leaves
- 351
- Edition
- 1
- Category
- Library
No coin nor oath required. For personal study only.
✦ Table of Contents
Table of Contents
About the Author
About the Technical Reviewer
Acknowledgments
Chapter 1: Getting Started
Monday: Introduction
What Is Python?
Why Python?
Why This Book?
Who This Book Is For?
What You’ll Learn
Tuesday: Setting Up Anaconda and Python
Cross-Platform Development
Installing Anaconda and Python for Windows
What Is Anaconda?
What Is Jupyter Notebook?
Wednesday: How to Use the Terminal
Changing Directories
Checking the Directory
Making Directories
Creating Files
Checking a Version Number
Clearing the Terminal Output
Using the Python Shell
Writing Your First Line of Python
Exiting the Python Shell
Thursday: Using Jupyter Notebook
Opening Jupyter Notebook
Step 1: Open Terminal
Step 2: Writing the Jupyter Notebook Command
Creating a Python File
Jupyter Notebook Cells
Friday: Creating Your First Program
Line Numbers Introduced
Creating the Program
Final Output
Weekly Summary
Weekly Challenges
Chapter 2: Python Basics
Monday: Comments and Basic Data Types
What Are Comments and Why Use Them?
Writing Comments
What Are Data Types?
The Print Statement
Integers
Floats
Booleans
Strings
Tuesday: Variables
How They Work
Handling Naming Errors
Integer and Float Variables
Boolean Variables
String Variables
Using Multiple Variables
Using Operators on Numerical Variables
Overwriting Previously Created Variables
Whitespace
Wednesday: Working with Strings
String Concatenation
Formatting Strings
.format()
f Strings (New in Python 3.6)
Formatting in Python 2
String Index
String Slicing
Thursday: String Manipulation
.title()
.replace()
.find()
.strip()
.split()
Friday: Creating a Receipt Printing Program
Final Design
Initial Process
Defining Our Variables
Creating the Top Border
Displaying the Company Info
Displaying the Product Info
Displaying the Total
Displaying the Ending Message
Displaying the Bottom Border
Weekly Summary
Challenge Question Solution
Weekly Challenges
Chapter 3: User Input and Conditionals
Monday: User Input and Type Converting
Accepting User Input
Storing User Input
What Is Type Converting?
Checking the Type
Converting Data Types
Converting User Input
Handling Errors
Code Blocks and Indentation
Tuesday: If Statements
How They Work
Writing Your First If Statement
Comparison Operators
Checking User Input
Logical Operators
Logical Operator “and”
Logical Operator “or”
Logical Operator “not”
Membership Operators
Membership Operator “in”
Membership Operator “not in”
Wednesday: Elif Statements
How They Work
Writing Your First Elif Statement
Checking Multiple Elif Conditions
Conditionals Within Conditionals
If Statements vs. Elif Statements
Thursday: Else Statements
How They Work
Writing Your First Else Statement
Complete Conditional Statement
Friday: Creating a Calculator
Final Design
Step #1: Ask User for Calculation to Be Performed
Step #2: Ask for Numbers, Alert Order Matters
Step #3: Set Up Try/Except for Mathematical Operation
Final Output
Weekly Summary
Challenge Question Solution
Weekly Challenges
Chapter 4: Lists and Loops
Monday: Lists
What Are Lists?
Declaring a List of Numbers
Accessing Elements Within a List
Declaring a List of Mixed Data Types
Lists Within Lists
Accessing Lists Within Lists
Changing Values in a List
Variable Storage
Copying a List
Tuesday: For Loops
How Loops Work
Writing a For Loop
Range()
Looping by Element
Continue Statement
Break Statement
Pass Statement
Wednesday: While Loops
Writing a While Loop
While vs. For
Infinite Loops
Nested Loops
Thursday: Working with Lists
Checking Length
Slicing Lists
Adding Items
.append()
.insert()
Removing Items
.pop()
.remove()
Working with Numerical List Data
Sorting a List
sorted()
.sort()
Conditionals and Lists
Using “in” and “not in” Keywords
Checking an Empty List
Loops and Lists
Using For Loops
Using While Loops
Friday: Creating Hangman
Final Design
Previous Line Symbols Introduced
Adding Imports
Declaring Game Variables
Generating the Hidden Word
Creating the Game Loop
Outputting Game Information
Checking a Guess
Clearing Output
Creating the Losing Condition
Handling Correct Guesses
Creating a Winning Condition
Outputting Guessed Letters
Adding Guessed Letters
Handling Previous Guesses
Final Output
Weekly Summary
Challenge Question Solution
Weekly Challenges
Chapter 5: Functions
Monday: Creating and Calling Functions
What Are Functions?
Function Syntax
Writing Your First Function
Function Stages
UDF vs. Built-in
Performing a Calculation
Tuesday: Parameters
What Are Parameters?
Passing a Single Parameter
Multiple Parameters
Passing a List
Default Parameters
Making Parameters Optional
Named Parameter Assignment
args
*kwargs
Wednesday: Return Statement
How It Works
Using Return
Ternary Operator
Thursday: Scope
Types of Scope
Global Scope Access
Handling Function Scope
In-Place Algorithms
Friday: Creating a Shopping Cart
Final Design
Initial Setup
Adding Items
Removing Items
Showing the Cart
Clearing the Cart
Creating the Main Loop
Handling User Input
Final Output
Weekly Summary
Challenge Question Solution
Weekly Challenges
Chapter 6: Data Collections and Files
Monday: Dictionaries
What Are Dictionaries?
Declaring a Dictionary
Accessing Dictionary Information
Using the Get Method
Dictionaries with Lists
Lists with Dictionaries
Dictionaries with Dictionaries
Tuesday: Working with Dictionaries
Adding New Information
Changing Information
Deleting Information
Looping a Dictionary
Looping Only Keys
Looping Only Values
Looping Key-Value Pairs
Wednesday: Tuples, Sets, Frozensets
What Are Tuples?
Declaring a Tuple
What Are Sets?
Declaring a Set
What Are Frozensets?
Declaring a Frozenset
Data Collection Differences
Thursday: Reading and Writing Files
Working with Text Files
Writing to CSV Files
Reading from CSV Files
File Modes in Python
Friday: Creating a User Database with CSV Files
Final Design
Setting Up Necessary Imports
Handling User Registration
Handling User Login
Creating the Main Loop
Weekly Summary
Challenge Question Solution
Weekly Challenges
Chapter 7: Object-Oriented Programming
Monday: Creating and Instantiating a Class
What Is an Object?
OOP Stages
Creating a Class
Creating an Instance
Creating Multiple Instances
Tuesday: Attributes
Declaring and Accessing Attributes
Changing an Instance Attributes
Using the init() Method
The “self” Keyword
Instantiating Multiple Objects with init()
Global Attributes vs. Instance Attributes
Wednesday: Methods
Defining and Calling a Method
Accessing Class Attributes in Methods
Method Scope
Passing Arguments into Methods
Using Setters and Getters
Incrementing Attributes with Methods
Methods Calling Methods
Magic Methods
Thursday: Inheritance
What Is Inheritance?
Inheriting a Class
Using the super() Method
Method Overriding
Inheriting Multiple Classes
Friday: Creating Blackjack
Final Design
Setting Up Imports
Creating the Game Class
Generating the Deck
Pulling a Card from the Deck
Creating a Player Class
Adding Cards to the Player’s Hand
Showing a Player’s Hand
Calculating the Hand Total
Handling the Player’s Turn
Handling the Dealer’s Turn
Calculating a Winner
Final Output
Weekly Summary
Challenge Question Solution
Weekly Challenges
Chapter 8: Advanced Topics I: Efficiency
Monday: List Comprehension
List Comprehension Syntax
Generating a List of Numbers
If Statements
If-Else Statements
List Comprehension with Variables
Dictionary Comprehension
Tuesday: Lambda Functions
Lambda Function Syntax
Using a Lambda
Passing Multiple Arguments
Saving Lambda Functions
Conditional Statements
Returning a Lambda
Wednesday: Map, Filter, and Reduce
Map Without Lambdas
Map with Lambdas
Filter Without Lambdas
Filter with Lambdas
The Problem with Reduce
Using Reduce
Thursday: Recursive Functions and Memoization
Understanding Recursive Functions
Writing a Factorial Function
The Fibonacci Sequence
Understanding Memoization
Using Memoization
Using @lru_cache
Friday: Writing a Binary Search
Final Design
Program Setup
Step 1: Sort the List
Step 2: Find the Middle Index
Step 3: Check the Value at the Middle Index
Step 4: Check if Value Is Greater
Step 5: Check if Value Is Less
Step 6: Set Up a Loop to Repeat Steps
Step 7: Return False Otherwise
Final Output
Weekly Summary
Challenge Question Solution
Weekly Challenges
Chapter 9: Advanced Topics II: Complexity
Monday: Generators and Iterators
Iterators vs. Iterables
Creating a Basic Iterator
Creating Our Own Iterator
What Are Generators?
Creating a Range Generator
Tuesday: Decorators
What Are Decorators?
Higher-Order Functions
Creating and Applying a Decorator
Decorators with Parameters
Functions with Decorators and Parameters
Restricting Function Access
Wednesday: Modules
Importing a Module
Importing Only Variables and Functions
Using an Alias
Creating Our Own Module
Using Our Module in Jupyter Notebook
Thursday: Understanding Algorithmic Complexity
What Is Big O Notation?
Hash Tables
Dictionaries vs. Lists
Battle of the Algorithms
Friday: Interview Prep
Developer Interview Process
What to Do Before the Interview
General Questions
Whiteboarding and Technical Questions
End of Interview Questions
What to Do After the Interview
Weekly Summary
Challenge Question Solution
Weekly Challenges
Chapter 10: Introduction to Data Analysis
Monday: Virtual Environments and Requests Module
What Are Virtual Environments?
What Is Pip?
Creating a Virtual Environment
Activating the Virtual Environment
Installing Packages
APIs and the Requests Module
Using the Requests Module
Sending a Request
Accessing the Response Content
Converting the Response
Passing Parameters
Tuesday: Pandas
What Is Pandas?
Key Terms
Installing Pandas
Importing Pandas
Creating a DataFrame
Accessing Data
Indexing by Column
Indexing by Record
Slicing a DataFrame
Built-in Methods
head()
tail()
keys()
.shape
describe()
sort_values()
Filtration
Conditionals
Subsetting
Column Transformations
Generating a New Column with Data
apply()
Aggregations
groupby()
mean()
groupby() with Multiple Columns
Adding a Record
drop_duplicates()
Pandas Joins
Creating a Second DataFrame
Inner Join
Outer Join
Dataset Pipeline
Wednesday: Data Visualization
Types of Charts
Installing Matplotlib
Importing Matplotlib
Line Plot
Bar Plot
Box Plot
Scatter Plot
Histogram
Importance of Histogram Distribution
Saving the Chart
Flattening Multidimensional Data
Thursday: Web Scraping
Installing Beautiful Soup
Importing Beautiful Soup
Requesting Page Content
Parsing the Response with Beautiful Soup
Scraping Data
.find()
.find_all()
Finding Elements by Attributes
DOM Traversal
Accessing the Children Attribute
Understanding the Types of Children
Accessing the Tag Object
Accessing the Head Element Tag
Scraping the Title Text
Friday: Web Site Analysis
Final Design
Importing Libraries
Creating the Main Loop
Scraping the Web Site
Scrape All Text
Filtering Elements
Filtering Waste
Count Word Frequency
Sort Dictionary by Word Frequency
Displaying the Top Word
Graphing the Results
Final Output
Weekly Summary
Challenge Question Solution
Weekly Challenges
Afterword:
Post-Course: What to Do Now?
Back-End Development with Python
Full-Stack Development with Python
Data Analysis with Python
Data Science with Python
Resources
Final Message
Index
📜 SIMILAR VOLUMES
Become a Python Programming Expert With Ease! Python is a simple yet powerful programming language that can enable you to start thinking like a programmer right from the beginning. It is very readable and the stress many beginners face about memorizing arcane syntax typically presented by other prog
Ready to start this new journey into the Python's world? Python is the ideal language to learn for budding developers. It is a modern object-oriented programming language with easy to read code and an extensive internet bank of modules. It offers high-level dynamic data types, many built-in func
<p>Build software that combines Python's expressivity with the performance and control of C (and C++). It's possible with Cython, the compiler and hybrid programming language used by foundational packages such as NumPy, and prominent in projects including Pandas, h5py, and scikits-learn. In this pra
Cython can yield massive performance improvements over pure Python--speedups of 3000X are easily attainable for certain patterns. With this book, Kurt Smith shows you how to use Cython to easily wrap C and C++ libraries in Python, handling all the details of memory management for you. By removing th