If you want to understand BRC-20 in depth, learn UTXO first
The recently popular BRC-20 Token is based on Bitcoin, but the Bitcoin blockchain cannot impose rules on it. The cost of making a BRC-20 Token lies in adding the file to the blockchain and the future movement of the UTXO associated with the Token.
Since UTXO is so important, today we will briefly introduce UTXO.
01. What is UTXO
In the current blockchain project, there are two main ways to save records, One is the account /Balance model, one is UTXO model. Bitcoin adopts the UTXO model, while Ethereum and others adopt the account/balance model.

unspent output, can be simply understood as return There are no spent receipts. For example, Han Meimei received a Bitcoin, but she did not use it. This Bitcoin is a UTXO to her.
02. Account/balance model and UTXO model
Account/balance model is very common in life, such as our bank account and WeChat account, all based on account/ Balance model.The balance in the account exists as a whole. How much money is in Li Lei's account? You can tell by looking at the balance. When a transaction occurs, it is the balance that changes. For example, on Valentine's Day, Li Lei transfers 520 yuan to Han Meimei via WeChat. Li Lei's WeChat account balance will decrease by 520 yuan, while Han Meimei's account balance will increase by 520 yuan.
The UTXO model is different from the account model.How many Bitcoins Li Lei has can only be known by summing up all the UTXOs of his Bitcoin address. To put it simply, the UTXO model is like the wallet we use, and each banknote or coin in the wallet is a separate UTXO. Therefore, it is not clear at a glance how much money is in the wallet. All banknotes and coin denominations need to be compared. It can be found by adding.
Every payment or receipt is consumed or received in UTXO units. For example, when we use 10 yuan to buy 5 yuan breakfast, the 10 yuan will be paid to the seller as a UTXO, and the seller will give you change. Let’s illustrate with an example. On Valentine's Day, Li Lei bought flowers for Han Meimei, the price was 520 yuan. To pay in cash, he took out 6 hundred-yuan bills (equivalent to 6 100-yuan UTXOs) and gave them to the seller. The seller needed to give Li Lei 80 yuan in change (one each of 50-yuan, 20-yuan and 10-yuan bills). It is obvious in this process that Li Lei spent 600 yuan to buy flowers and received 80 yuan in change, and the seller sold the flowers and received 520 yuan. From the perspective of UTXO, Li Lei spent 6 UTXO (6 pieces worth 100 yuan) and got 3 UTXO (3 pieces in change); the seller got 6 UTXO and spent 3 UTXO in change. If this transaction is completed with Bitcoin, the process will be slightly different. Suppose Li Lei uses 6 UTXOs of 1 BTC to pay the seller 5.2 BTC. In the end, the seller getsa value of 5.2 BTC. UTXO, The change given to Li Lei is a UTXO worth 0.8 BTC. In other words, 6 UTXOs were "destroyed" and turned into two new UTXO. (The reason for the difference between the two is that the types of banknote denominations are limited, while Bitcoin is not subject to this restriction). If the show of affection between Li Lei and Han Meimei takes place on the Bitcoin network, what is the transfer process?
Li Lei mined and received 12.5 Bitcoins as a reward from the system, so there was a UTXO of 12.5 BTC on Li Lei’s Bitcoin address.
Li Lei wants to transfer 5.2BTC to Han Meimei, and the 12.5BTC UTXO will be spent as a whole, of which 5.2BTC will be transferred to Han Meimei, and the remaining 7.3BTC will be given to himself in change (for the convenience of discussion, I will ignore it here Mining fees). In other words, 12.5 BTC previously existed in the form of a UTXO. During the transfer, this UTXO was "destroyed" and no longer existed. It became two new UTXOs: one belonged to Han Meimei, and the value of this UTXO 5.2BTC, the other one belongs to Li Lei, this UTXO is worth 7.3BTC, this is the change given to Li Lei.

03. Summary
The core design idea of UTXO is: it records transaction events but not the final status. To calculate how many Bitcoins a user has, it is necessary to sum up all the UTXOs in his wallet, and the result is the number of coins he holds. The UTXO model uses UTXO as the unit when transferring transactions, which means that when making a payment, an integer multiple of UTXO is called, such as 1 UTXO, 3 UTXO, and there is no such thing as 0.5 UTXO.
Bitcoin’s General transactions: call one UTXO to pay other people, and Collection transactions: call multiple UTXOs to pay other people.
Can you name other types of transactions?
The above is the detailed content of If you want to understand BRC-20 in depth, learn UTXO first. For more information, please follow other related articles on the PHP Chinese website!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

The most suitable platforms for trading Meme coins include: 1. Binance, the world's largest, with high liquidity and low handling fees; 2. OkX, an efficient trading engine, supporting a variety of Meme coins; 3. XBIT, decentralized, supporting cross-chain trading; 4. Redim (Solana DEX), low cost, combined with Serum order book; 5. PancakeSwap (BSC DEX), low transaction fees and fast speed; 6. Orca (Solana DEX), user experience optimization; 7. Coinbase, high security, suitable for beginners; 8. Huobi, well-known in Asia, rich trading pairs; 9. DEXRabbit, intelligent

Cryptocurrency data platforms suitable for beginners include CoinMarketCap and non-small trumpet. 1. CoinMarketCap provides global real-time price, market value, and trading volume rankings for novice and basic analysis needs. 2. The non-small quotation provides a Chinese-friendly interface, suitable for Chinese users to quickly screen low-risk potential projects.

The ranking of virtual currencies’ “oldest” is as follows: 1. Bitcoin (BTC), issued on January 3, 2009, is the first decentralized digital currency. 2. Litecoin (LTC), released on October 7, 2011, is known as the "lightweight version of Bitcoin". 3. Ripple (XRP), issued in 2011, is designed for cross-border payments. 4. Dogecoin (DOGE), issued on December 6, 2013, is a "meme coin" based on the Litecoin code. 5. Ethereum (ETH), released on July 30, 2015, is the first platform to support smart contracts. 6. Tether (USDT), issued in 2014, is the first stablecoin to be anchored to the US dollar 1:1. 7. ADA,

When choosing a digital currency trading platform suitable for beginners, you need to consider security, ease of use, educational resources and cost transparency: 1. Priority is given to platforms that provide cold storage, two-factor verification and asset insurance; 2. Apps with a simple interface and clear operation are more suitable for beginners; 3. The platform should provide learning tools such as tutorials and market analysis; 4. Pay attention to hidden costs such as transaction fees and cash withdrawal fees.

The top ten digital virtual currency apps are: 1. OKX, 2. Binance, 3. gate.io, 4. Coinbase, 5. Kraken, 6. Huobi, 7. KuCoin, 8. Bitfinex, 9. Bitstamp, 10. Poloniex. These exchanges are selected based on factors such as transaction volume, user experience and security, and all provide a variety of digital currency trading services and an efficient trading experience.

The core advantage of gate.io (global version) is that the interface is minimalist, supports Chinese, and the fiat currency trading process is intuitive; Binance (simplified version) has the highest global trading volume, and the simple version model only retains spot trading; OKX (Hong Kong version) has the simple version of the interface is simple, supports Cantonese/Mandarin, and has a low threshold for derivative trading; Huobi Global Station (Hong Kong version) has the core advantage of being an old exchange, launches a meta-universe trading terminal; KuCoin (Chinese Community Edition) has the core advantage of supporting 800 currencies, and the interface adopts WeChat interaction; Kraken (Hong Kong version) has the core advantage of being an old American exchange, holding a Hong Kong SVF license, and the interface is simple; HashKey Exchange (Hong Kong licensed) has the core advantage of being a well-known licensed exchange in Hong Kong, supporting France

Can. The two exchanges can transfer coins to each other as long as they support the same currency and network. The steps include: 1. Obtain the collection address, 2. Initiate a withdrawal request, 3. Wait for confirmation. Notes: 1. Select the correct transfer network, 2. Check the address carefully, 3. Understand the handling fee, 4. Pay attention to the account time, 5. Confirm that the exchange supports this currency, 6. Pay attention to the minimum withdrawal amount.

Domestic user adaptation solutions include compliance channels and localization tools. 1. Compliance channels: Franchise currency exchange through OTC platforms such as Circle Trade, domestically, they need to go through Hong Kong or overseas platforms. 2. Localization tools: Use the currency circle network to obtain Chinese information, and Huobi Global Station provides a meta-universe trading terminal.