Position: Home page » Blockchain » Blockchain Python tutorial

Blockchain Python tutorial

Publish: 2021-05-16 00:37:05
1. At present, there are not many videos on the market for systematic learning of blockchain, and self-learning of blockchain is still relatively rare. You can apply for classes. Black horse programmers will open a new blockchain discipline. Teachers will teach in an easy-to-understand way and explain in simple terms. You can certainly learn it.
2. Initial blockchain
features:
blockchain is an immutable and orderly chain record composed of block records. The main features are as follows:
1: decentralization
e to the use of Distributed Accounting and storage, there is no centralized hardware or management organization, the rights and obligations of any node are equal, and the data blocks in the system are jointly maintained by the nodes with maintenance function in the whole system. Thanks to the decentralization of blockchain, bitcoin also has the characteristics of decentralization
2: openness
the system is open, in addition to the private information of the parties to the transaction is encrypted, the data of the blockchain is open to all, and anyone can query the blockchain data and develop related applications through the open interface, so the information of the whole system is highly transparent
3: autonomy
blockchain adopts consensus based specifications and Protocols (such as a set of open and transparent algorithms) to enable all nodes in the whole system to exchange data freely and safely in a de trusted environment, so that the trust in "people" is changed into the trust in machines, and any human intervention does not work
4: information cannot be tampered with
once the information is verified and added to the blockchain, it will be stored permanently. Unless more than 51% of the nodes in the system can be controlled at the same time, the modification of the database on a single node is invalid, so the data stability and reliability of the blockchain are extremely high
5: anonymity
since the exchange between nodes follows a fixed algorithm, their data interaction does not need to be trusted (the program rules in the blockchain will judge whether the activity is effective by themselves), so the counterparties do not need to make the other party trust themselves by disclosing their identities, which is very helpful for credit accumulation
compared with the traditional distributed database, there are two main differences:
1: the traditional distributed database supports adding, deleting, checking and modifying, while the blockchain only supports searching and inserting, and blocks cannot be deleted or modified
2: the traditional distributed database is generally a master-slave structure: master and slaves structure. In order to ensure high availability, it is realized by standby master, while the blockchain is a decentralized database. There is no master-slave structure
blockchain and bitcoin:
when it comes to blockchain, most people talk about bitcoin. However, blockchain is not equal to bitcoin. It is now the era of blockchain 3.0, and bitcoin is only the proct of blockchain 1.0
the evolution mode of blockchain is:
& ᦇ 9642; Blockchain 1.0 digital currency; Blockchain 2.0 digital assets and smart contracts; Blockchain 3.0 - Implementation of distributed applications in various instries
classification of blockchain:
public blockchains
public blockchain means that any indivial or group in the world can send transactions, and transactions can be effectively confirmed by the blockchain, and anyone can participate in its consensus process. Public blockchain is the earliest and the most widely used blockchain. The virtual digital currencies of bitcoin series are all based on public blockchain. There is only one blockchain corresponding to this currency in the world
consortium blockchains
instry blockchains: multiple preselected nodes are designated as bookkeepers within a certain group, and the generation of each block is jointly determined by all preselected nodes (preselected nodes participate in the consensus process). Other access nodes can participate in transactions, but not the bookkeeping process (essentially, trusteeship bookkeeping), It just becomes distributed accounting, the number of preselected nodes, and how to determine the bookkeeper of each block to become the main risk point of the blockchain). Anyone else can conct limited query through the open API of the blockchain
private blockchain: it only uses the general ledger technology of blockchain for bookkeeping. It can be a company or an indivial, enjoying the write permission of the blockchain. This blockchain is not very different from other distributed storage schemes Dec2015) conservative giants (traditional finance) want to experiment with private blockchain, while the application of public chain, such as bitcoin, has been instrialized, and the application procts of private chain are still groping.
3.

Can be

blockchain to achieve a simple description of the principle of

blockchain technology as a digital accounting technology, its core is to save the transaction data block, in the form of encryption, according to the order of time chain record. Blockchain itself is a public database. The system stores the new business data in a container called block, and adds the block to the chain composed of existing blocks. It's a bit like a snake. The more you eat, the longer the snake's body; In the application scenario of bitcoin, the data is a set of transfer transaction records. In the application scenario of bike sharing, these data can be the transaction records of car borrowing and returning

The simple implementation code of

blockchain

in the above code, the data structure stored in the core of blockchain is list, which can be accessed through
new_ New blocks generated by block () are constantly added to the end of the blockchain. The hash value of each block contains all the data information of the block. In the process of calculating the hash
value, the hash
value of the previous block needs to be referenced, so tamper proof is realized. The biggest value of blockchain database is this highly tamper proof trusted computing. This has been successfully demonstrated in our simple blockchain implementation. In commercial level blockchain applications, the process of creating new blocks is called smart contract, and blockchain is growing through smart contract

the following is the running result of the code, which is different at different times

running results

< img / >

4. Blockchain is a new application mode of distributed data storage, point-to-point transmission, consensus mechanism, encryption algorithm and other computer technologies. The so-called consensus mechanism is a mathematical algorithm to establish trust and obtain interests between different nodes in the blockchain system
and Python is an object-oriented interpretive computer programming language
it's better to learn together without conflict. I think it's Python because it's a language that can do a lot of things.
5. /**
******************************************************************************
* @file stm32_eth.c
* @author MCD Application Team
* @version V1.1.0
* @date 11/20/2009
* @brief This file provides all the ETH firmware functions.
******************************************************************************
* @
*
* THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
* WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE
* TIME. AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY
* DIRECT, INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING
* FROM THE CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE
* CODING INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.
*
* <h2><center>© COPYRIGHT 2009 STMicroelectronics</center></h2>
*/
6.

1. Technical language

Python and go are two technical languages mentioned by many companies. Learning needs to be a priority. Moreover, these two languages have great application in the technical direction outside the blockchain. For example, go is used in the background construction of large concurrent systems, and Python is used in the construction of artificial intelligence systems. So learning these two languages is a priority

2. Technical framework

master one or more of bitcoin, Eth and hyperledger. Needless to say, BTC is written in C + +. A large number of currency projects, such as lightcoin, dash, Monroe, zcash, use bitcoin technology for secondary development

eth is the representative of blockchain 2.0, which can build a variety of application classes DAPP on eth network. Now a large number of application blockchain projects are developed using eth platform

hyperledger fabric is a blockchain development platform pushed by IBM, which is mainly used for the development of alliance chain, and is the most popular alliance chain development platform at present

3, algorithm

pow (proof of work), POS (proof of rights and interests algorithm), pbft (Byzantine fault-tolerant algorithm) are all important components of cryptography in blockchain. A full understanding of these algorithms will help you to have a better understanding of cryptography when you participate in the underlying development of blockchain projects



extended data:

blockchain technology is a kind of Distributed Accounting Technology, which is characterized by decentralization, openness and transparency, so that everyone can participate in the establishment of the database, and each established data can not be tampered with, and everyone participates, The problem of trust between strangers is solved

blockchain technology has emerged. It is an accounting technology with the participation of the whole people. The transaction information and data between AB and ab are published to the public and can not be tampered with. As we all know, there is no need for any authoritative Third Party C here. In other words, everyone in the system plays the role of C, which is also called decentralization

7.

Thank you for your comments. If you know your mistake, change it

The back (4) of 10 bars (25) indicates that there are 4 longitudinal reinforcement bars not passing through the column section and 2 bars on both sides of the column (in short, 10 bars (4) means 6 longitudinal reinforcement bars passing through the column section, 4 longitudinal reinforcement bars not passing through the column section and 2 bars on both sides of the column)

these 10 pieces of 25 (4) are the contents marked in the beam set. There are five required values and one special case not specified in the optional value provisions. is only applicable to frame flat beam

the screenshot is an example on page 31 of 16g101-1 (instead of 11g101-1) concrete structure construction drawing, drawing rules and structural details (cast-in-place concrete frame, shear wall, beam and slab)

8. The frame flat beam has 2 and 3 spans, and the dimension is beam width 650 * beam height 500
Hot content
Inn digger Publish: 2021-05-29 20:04:36 Views: 341
Purchase of virtual currency in trust contract dispute Publish: 2021-05-29 20:04:33 Views: 942
Blockchain trust machine Publish: 2021-05-29 20:04:26 Views: 720
Brief introduction of ant mine Publish: 2021-05-29 20:04:25 Views: 848
Will digital currency open in November Publish: 2021-05-29 19:56:16 Views: 861
Global digital currency asset exchange Publish: 2021-05-29 19:54:29 Views: 603
Mining chip machine S11 Publish: 2021-05-29 19:54:26 Views: 945
Ethereum algorithm Sha3 Publish: 2021-05-29 19:52:40 Views: 643
Talking about blockchain is not reliable Publish: 2021-05-29 19:52:26 Views: 754
Mining machine node query Publish: 2021-05-29 19:36:37 Views: 750