Hello! I am new person in blockchain technology and I want to fasten my knowledges by writing own primitive version of blockchain. I can not understand where will be my blockchain store wallets public addresses for transactions between users.
Your wallet is able to create almost unlimited public addresses. Your wallet is basically a seed, which is a mathematical function that canl generate many addresses mathematically related (from that seed).
Those addresses have UTXO (unspent transaction outputs) registered to them, if they have any balance available for them to spent.
Those UTXO are stored in every node in the network (the blockchain), not the addresses or the seed or the wallet, but the UTXO.
from mastering bitcoin by Antonopoulos
There are no accounts or balances in bitcoin; there are only unspent transaction outputs (UTXO) scattered in the blockchain. Users cannot cut a UTXO in half any more than they can cut a dollar bill in half and use it as currency.
Sending someone bitcoin is creating an unspent transaction output (UTXO) registered to their address and available for them to spend.
https://github.com/bitcoinbook/bitcoinbook