- A token standard allows for ERC-20 tokens to be inter-operable.
- transfer() sends tokens to another address from the msg.sender. approve() allows for another address to spend a certain amount of tokens. transferFrom() is used after the approve() function to send tokens from one address to another. totalSupply() gets the total supply of tokens. balanceOf() gets the token balance of an address. allowance() checks the amount of tokens that the owner allowed the spender.
-
What are the benefits of setting a token standard like ERC20?
Allows wallets to provide token balances for hundreds of different tokens and creates a way for exchanges to list more tokens by providing just the address of the tokenâs contract. -
What functions are in the ERC20 Token Standard Interface and what do they do?
Name - Token Contract long name
Symbol - Token Contract short name - usually 3 letters
Decimals - How divisible a token can be usually ranging from 1 to 18 but can be higher if necessary.
Total Supply - Sum of all token balances
Balanceof - number of tokens held in a particular address.
Transfer - transfer tokens between different address with no checks
Approve - Token holder gives authority (usually via a smart contract) to token receiver to transfer a certain number of tokens from the sender.
Allowance - number of tokens approved to be transferred. Also fails the transaction if not enough tokens in senderâs account.
Transferfrom - address of account from which tokens can be taken.
-
To avoid a random design of token and all the communities can communicate with each other. Since we have an unified standard, the wallet, exchanges etc can easilz operate on all tokens within this standard.
-
âtotalSupplyâ can tell us how many tokens is circulating in the network. âbalanceof(account adress)â can tell the balance of this adress.
- What are the benefits of setting a token standard like ERC20?
It makes sure that the code is consistent. It also allows the economies created to be easier to create than if there was not a standard.
- What functions are in the ERC20 Token Standard Interface and what do they do
They are fungible tokens which means they have a store of value and can be redeemed within the crypto currency. They can also be transferred from one token user to another. They allow you to create economies on top of cryptocurrencies.
- What are the benefits of setting a token standard like ERC20?
Smart contracts which are programmable
2. What functions are in the ERC20 Token Standard Interface and what do they do
Answered previously
- that everybody is using the same naming and programming conventions for ERC20 tokens which also makes it possible that new tokens can immediately be supported by exchanges that can use the same commands
- balanceOf() = provides number of tokens held by a given address
- transfer() = transfers a number of tokens directly from the message sender to another address (fine for sending tokens from one to another address but not so well to enact a payment from a smart contract)
- approve() / transferFrom() - giving another address approval to transfer up to a certain number fo tokens (allowance), the token holder uses âapprove()â to provide this information
- allowance() = provides the number of tokens allowed to be transferred from a given address by another given address
What are the benefits of setting a token standard like ERC20?
Enhances communication speed and efficiency amongst all fungible tokens built on ethereum.
What functions are in the ERC20 Token Standard Interface and what do they do?
total supply: tells tokens in circulation
Balance of: tells balance of specific address
Transfer: allows for token transfer
- What are the benefits of setting a token standard like ERC20?
You can build token economies (coins) - What functions are in the ERC20 Token Standard Interface and what do they do?they allow for fungible coins
ERC20 Token Answers.
-
Having a token standard like the ERC20 allows for a standard way for every developer to program and deploy tokens on the Ethereum network. This act of fungibility allowing for all tokens to function in the same way, laying out the code, in the same way, allows for all exchanges and wallets to support them from day one.
-
One of the functions of the many ERC20 token standard is The
balanceOf()
function. Which provides the number of tokens held by any given address.
-
What are the benefits of setting a token standard like ERC20?
Setting ERC20 standard to all tokens make the tokens supported by any wallet and nodes in the Ethereum network. -
What functions are in the ERC20 Token Standard Interface and what do they do?
ERC20 has funcions such as balanceOf(), transfer(), transferFrom(), etc.
1. What are the benefits of setting a token standard like ERC20?
- After setting an agreed-upon solution, that satisfies all the best practices and security conventions, there is no need for reinventing the wheel (and probably reinventing it with bugs). When the majority of the projects implements this standard (interface), it becomes easy for exchanges and other developers to interact with these tokens. It also helps the transparency and auditability of the tokens, as we know what we should expect from that token.
2. What functions are in the ERC20 Token Standard Interface and what do they do?
- totalSupply() - getting the overall number of tokens in circulation
- balanceOf(address) - getting the balance (amount of tokens) in control of a specified address
- transfer(to_address, amount) - sending tokens to some specific address (the sender address is implicit there)
- approve(spending_address, amount) - allow other address (most often a smart contract) to spend tokens up to a specified amount
- allowance(owner_address, spending_address) - getting the amount that one address allowed to be spent to the second address
- transferFrom(from_address, to_address, amount) - sending tokens through allowance from one address to another
What are the benefits of setting a token standard like ERC20?
This helps other software (likes wallets and exchanges) to be able to interact with this token up front. Anyone who creates a token based on this standard can instantly be deployed on all these tools without any additional implementation being needed.
What functions are in the ERC20 Token Standard Interface and what do they do?
- balanceOf()
- transfer()
- approve()
- transferFrom()
- allowance()
-
What are the benefits of setting a token standard like ERC20?
In one word : compatiblity. Compatibility accross the network! That way, many tools (like the uniswap Dex) can use variants of tokens. -
What functions are in the ERC20 Token Standard Interface and what do they do?
name() : returns the name of the token.
symbol() : returns the âtickerâ like symbol of the token.
decimals() : returns the number of decimals used by the token, thus defining itâs precision.
totalSupply() : returns the total number of tokens.
balanceOf() : return the token held by an address.
transfer() : transfers tokens to an address. Example : an airdrop.
transferFrom(): transfers tokens from an adress to another. Example : normal transaction.
approve() : âpre authorizeâ withdrawals(up to a max value) from a specific address to another one.
allowance() : returns how many tokens can be withdrawn with the approve() function.
- Compatibility. A standard like ERC20 permits exchanges and wallets to be set up and programmed to support any new token using the same standard.
totalSupply () max no of tokens in existence.
transfer() transfer tokens from one address to another
balanceOf(address account) gives a public adressesâ balance of ERC20 tokens.
- What are the benefits of setting a token standard like ERC20?
standars are very important, especially in the crypto world, that is what allows us to exchange tokens in descentralized exchanges.
without the standard every coin would be unique
- What functions are in the ERC20 Token Standard Interface and what do they do?
balanceOf (address)
totalSupply()
those two are mentioned in the lecture.
-
What are the benefits of setting a token standard like ERC20?
Allows wallets and exchanges to easily accept all ERC20 tokens. They all share the same code. -
What functions are in the ERC20 Token Standard Interface and what do they do?
Programs fungible standard tokens thru Solidity.
totalSupply() gives maximum number of tokens that exist
balanceOf(address account) gives a public addressesâ balance of ERC20 tokens
transfer() allows someone to transfer their ERC20 tokens to another public address
-
What are the benefits of setting a token standard like ERC20?
Interoperability between smart contracts, tokens. Wallets exchanges ready for ERC20 standard can automatically work with any token using this standard. -
What functions are in the ERC20 Token Standard Interface and what do they do?
- totalSupply(), to provide the maximum total amount of tokens that exist or will exist in the smart contract.
- balanceOf(address), the balance of an specific address.
These are the two specifically covered in the video.
What are the benefits of setting a token standard like ERC20?
Consistency, Efficiency, Scalability so the network can talk to each other in a common language
What functions are in the ERC20 Token Standard Interface and what do they do?
balanceOf(): provides the number of tokens held by a given address.
transfer(): transfers a number of tokens directly from the message sender to another address. But it doesnât work well when tokens are being used to pay for a function in a smart contract.
approve(): a token holder gives another address approval to transfer up to a certain number of tokens(allowance).
transferFrom(): take certain tokes from senderâs account and carry on its work.
doSomething(): to operate instructions.
allowance(): provides the number of tokens allowed to be transferred from a given address by another given address
- Benefits of setting a token standard like the ERC20 allows wallets, exchanges to communicate and be compatible with one another, increasing efficiency.
- total supply - how many tokens will there be
- balanceOf - shows account balance
- transferFrom - is this a receive function?
- approve - send tokens?
- allowance - return a set number of tokens from a spender to the owner
- havenât the same ERC20 platform allows for multiple tokens to be built on the same platform instead of thousands of individual ones which increases efficiency
2)totalsupply, balanceOf(account), transfer, approve to name a few