Learn Python by Building a Blockchain and Cryptocurrency
Video description
Learn Python from the ground up and use Python to build your own basic Blockchain and Cryptocurrency (Coin)!
About This Video
Use Python to build your own basic Blockchain and Cryptocurrency (Coin)!
Dive into web development and data science with Python
In Detail
Python is easy-to-use and extremely versatile and powerful, making it one of the most popular programming languages. Python offers both object-oriented and …
Learn Python by Building a Blockchain and Cryptocurrency
Video description
Learn Python from the ground up and use Python to build your own basic Blockchain and Cryptocurrency (Coin)!
About This Video
Use Python to build your own basic Blockchain and Cryptocurrency (Coin)!
Dive into web development and data science with Python
In Detail
Python is easy-to-use and extremely versatile and powerful, making it one of the most popular programming languages. Python offers both object-oriented and structural programming features. The Blockchain technology is an exciting trend that’s here to stay.
This course will take you on a journey where you’ll learn Python by building a Blockchain and Cryptocurrency. It's very popular because it's easy to learn and use, runs on all operating systems, and allows you to build a broad variety of programs, be it web applications, desktop applications, utility scripts, or for data science and machine learning.
In this course, you'll learn a lot about the core concepts of the Blockchain and see how Python can be used for the many aspects that make up a Blockchain and Cryptocurrency. As a nice side-effect, you’ll see how a Blockchain works. This course will show you how to use Python to build your own basic Blockchain and Cryptocurrency (Coin). We’ll dive into the basics of Python and you’ll understand the complex data structures.
Understanding a “Special” Behavior when Working with Numbers
Working with Strings
Working with Lists
Adding Removing List Items
Preparing the Blockchain - The Theory
Installing our IDE
Using Functions to Add List Items
Accessing the Last List Item
Adding Arguments to Functions
Understanding the “return” Keyword
Using Default Arguments
Working with Keyword Arguments
Using the “input” Function
Avoiding Repetitive Code Execution
Understanding the Variable Scope
Exploring the Official Documentation
Adding Comments and Doc Strings
Structuring Multi Line Code in Python
Wrap Up
Chapter 3 : Working with Loops Conditionals
Module Introduction
Understanding Loops - Theory
Creating a “for” Loop
Creating a “while” Loop
Understanding Conditionals - Theory
Adding “if-else” to our Blockchain
Working with “elif”
Understanding “break” “continue”
Improving our Code with Loops Conditionals
Understanding Boolean Operators - “is” “in”
The “not” Keyword
Understanding “and” and “or”
Grouping Conditionals
What About “switch” in Python?
Verifying our Blockchain
Using Conditions inside the “while” Loop
Using “else” in Loops
Adding the “range” Function
Wrap Up
Chapter 4 : Understanding Complex Data Structures
Module Introduction
Understanding the Required Data Structure for our Blockchain
Working with Iterables
Choosing the Right Datastructure
Transactions with Dictionaries Tuples
Unpacking the Tuple
Mining Blocks
Hashing Previous Blocks
Understanding List Comprehensions
And What are Dict Comprehensions?
Combining List Comprehensions “if”
Improving the Blockchain Validation Logic
Managing a List of Participants in the Blockchain
Calculating Balances
Rewarding the Miners of our Blockchain
Verifying Transactions
Understanding Reference vs Value Copying.
Working with the Range Selector
Understanding Shallow vs Deep Copies
Comparing “is” “==”
Diving Deeper Into Iterable Methods
Understanding the “all” “any” Functions
Comparing Iterables
Wrap Up
Chapter 5 : Working with Functions Strings
Module Introduction
Comparing Strings Lists
Understanding the “format” Method
Escaping Characters
Formatting Strings Conveniently with “f”
Adding String Formatting to our Project
Understanding the “map” Function
Working with Lambda Functions
Reducing Lists
Unpacking Function Arguments
Fixing a Bug
Wrap Up
Chapter 6 : Working the Python Standard Library
Module Introduction
Exploring the Python Standard Library
Importing Packages - Theory
Importing “hashlib” to create a Unique Hash
Using Other Import Syntaxes
The “Proof of Work”
Adding the Proof of Work to our Blockchain
Including the Proof of Work in our Mining Function
Fixing a Hash Order Fault
Splitting Up our Code
Wrap Up
Chapter 7 : Working with Files
Module Introduction
Handling File Access
Reading Data from a File
Reading Multi-Line Content
Using the “with” Block Statement
Adding File Access to our Blockchain
Converting Strings into Python Objects
Storing Data with Pickle
Comparing Pickle JSON
Changing the Project Back to JSON
Why we need Proper Error Handling
Wrap Up
Chapter 8 : Handling Errors Debugging
Module Introduction
Finding Logical Errors with the Debugger
Finding Syntax Errors
Using “try” to Find Runtime Errors
Which Errors Should you Handle?
Adding Error Handlers to our Blockchain
Wrap Up
Chapter 9 : Object Oriented Programming
Module Introduction
What is Object Oriented Programming?
Understanding Classes
Creating a Class
Comparing Classes, Instances Dictionaries
Understanding Class Attributes
Constructor Instance Attributes
Printing Classes with Special Methods
Private Public Attributes
Understanding Inheritance
Planning Blockchain Classes
Adding a “Block” Class to the Blockchain
Saving Custom Class Objects via .json
Adding a “Transaction” Class
Inheritance in Action
Adding a “Verification” Helper Class
Initialising the “Node” Class
Turning the Blockchain into a Class
Adding a “Node” Class
Understanding “Instance” vs “Class” vs “Static Methods” “Attributes”
Using “Static” “Class” Methods on the “Verification” Class
Using Private Attributes in the Blockchain
Properties vs Attributes
Wrap Up
Chapter 10 : Modules
Module Introduction
Creating Packages - Module Bundles
The “pycache” Folder
Module Docstrings
Controlling Exports
Understanding Execution Context “name”
Why we need a Private Public Key Transaction Protection
Using Anaconda to Install Third Party Packages
Generating Keys with a Third Party Package
Connecting the Node the Wallet
Generating Keys on the Node
Saving Loading Keys to Files
Creating Transaction Signatures
Adding a Signature to our Transactions
Verifying Signatures
Improving the Verification Logic
Wrap Up
Chapter 11 : Adding HTTP with Flask
Module Introduction
HTTP Requests - The Basics
Understanding API-Endpoints/ URLs
Data Formats
Planning our API
Setting Up our Environment with Flask
Adding our First Route
Installing Postman
Adding a POST Request
Setting Up Routes to Manage our Wallet
Returning Funds
Adding Transactions
Fetching Open Transactions
Testing the Public Key
Adding a User Interface
Optional: Configuring our UI - Creating a Wallet
Optional: Configuring our UI - Loading a Wallet and Adding Mining Transactions
Exploring our UI
Wrap Up
Chapter 12 : The Node Network
Module Introduction
Adding Node Management Methods to the Blockchain
Setting Up Routes to Add Nodes
Adding a Remove Node Route
Adding “get_Nodes” to get all Nodes
Attaching a Node User Interface
Running Multiple Nodes
Sending Requests from within Python
Broadcasting Transactions - Adding the Function Route
Broadcasting Transactions - Testing Fixing Errors
Broadcasting New Blocks: Adding the Function Route
Broadcasting New Blocks: Informing the Peer Nodes
Broadcasting Transactions: Testing
Solving Conflicts
Understanding Consensus
Finding Conflicts
Implementing a Consensus Algorithm
Testing Consensus
Wrap Up
Chapter 13 : Next Steps and Course Roundup
Module Introduction
Don’t Forget PEP 8
Using PEP 8
Using Comments
Diving Deeper Into Python
Improving the Blockchain
Congratulations
Start your Free Trial Self paced Go to the Course We have partnered with providers to bring you collection of courses, When you buy through links on our site, we may earn an affiliate commission from provider.
This site uses cookies. By continuing to use this website, you agree to their use.I Accept