-
It is a standardized programming language making it efficient and possible to be audited and accepted by exchanges.
-
balanceOf() - this is to check the balance of a specific address
transfer( )- transfer tokens from 1 address to another
approve( )- approve a transaction
-
It makes it easier for different projects to integrate with eachother and more efficient when it comes to different exchanges/wallets that can read/use same functions and that makes it easier for all parties to interact with each other and it results in smaller amount of code.
-
A function where you can check the total supply of tokens(totalSupply) another is to check the balance of a account(balanceOf) and a function to be able to transfer tokens(transfer) and a function where you can give it instructions(doSomething) a function for approval, gives approval to an address so it can withdraw tokens from your account, in the same way as a smart contract is used(approve) and returning from an address(transferFrom)
Homework on ERC20 token standard.
- What are the benefits of setting a token standard like ERC20?
⢠Setting standards eliminates friction within the ERC20 contract. Without standards programmers would not stay within the parameters of a set language and chaos would therefore ensue.
- What functions are in the ERC20 Token Standard Interface and what do they do?
ERC20 tokens comes with a variety of functions that allow users to determine the value of accounts as well as to transfer those values from one account to another. These functions are:
⢠balanceOf () - Gives the number of tokens in a given address.
⢠transfer () - Is pretty self explanatory. It transfers tokens from the sender to intended recipient.
⢠approve () - Token holder uses this command to provide information, known as an allowance.
⢠allowance () - This function provides the number of tokens that are allowed to be taken from one address and given to another.
⢠doSomething () - Operation instructions.
⢠transferFrom () - The ability for the sender to transfer a certain amount of tokens.
-
What are the benefits of setting a token standard like ERC20?
Answer: A token standard like ERC20 allows a programming standard for the tokens that can be built on top of Ethereum. This streamlines interoperability for exchanges and wallets to interact with various different ERC20 tokens. This standardization allows for the token to be fungible and for the network to reach maximum efficiency. -
What functions are in the ERC20 Token Standard Interface and what do they do?
Answer:
totalSupply() - get the total token supply
balanceOf() - returns the number of tokens in a given address
transfer() - transfers a specified number of tokens from one address to another
approve() - allows the spender to withdraw from your account, multiple times, up to a certain amount
transferFrom() - returns the amount that a spender is allowed to withdraw from the owner
- all wallets can talk with other coins freely
2.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
Response:
- Using a standard creates efficiency between tokens by requiring them to stick to functions that have been pre-set. This also helps wallets to support tokens using ERC20 as it is more streamlined and easier to deal with one benchmark as opposed to hundreds of different and unique codes.
- Functions of ERC20 are âtotal supplyâ (gives the supply of the token), âbalanceOfâ (retrieves the specified balance of the 0x account in question), âtransferâ (moves token from one acct to another).
-
What are the benefits of setting a token standard like ERC20?
Like other standards it tells how to use Ethereum tokens and assures common practices for handling the tokens using the same functions, naming. -
What functions are in the ERC20 Token Standard Interface and what do they do?
totalSupply() returns the maximum number of tokens in circulation
balanceOf(address account) takes a parameter of the account address and returns the balance of that account in number of tokens
transfer(recipient address, amount) takes parameters recipient address and amount and transfers a number of tokens (amount) directly from the message sender to the recipient address.
-
What are the benefits of setting a token standard like ERC20?
It allows easy fungibility btwn tokens cuz the tokens all function in the same manner via the same commands. -
What functions are in the ERC20 Token Standard Interface and what do they do?
totalsupply - how many tokens have been issued and are in circulation
transfer - move tokens from 1 account to another
balanceOf - whatâs the balance of your token(s) dude?
doSomething - doer has a smart contract that has to do something dude
-
With standards (like ERC20) we can achieve efficiency, we can easily interoperate with each other and. It makes it easy to build project (and deploy tokens) on top of ethereum network.
-
For example:
totalSupply() - how many tokens are in circulation
balanceOf() - what is the balance (how much tokens) of an account (input data - address of the account)
- As the ERC20 token is standard, the benefits are that exchanges and wallets can accept them immediately without any code re-writes. As the format for the token is identical in every case it also makes the creation of the tokens extremely easy. The direct consequence is that administration is minimal.
- If you want to create a token you must write a smart contract. The format of that contract is a standard structure and can contain 3 optional functions but MUST contain 6 mandatory functions:
Optional functions are:
a. Token name - Uncle Benâs Token
b. Token Symbol (UBT)
c. Decimals - this is how divisible you want your tokens to be - two decimal points if you want to divide it by 100 or 3 decimal points if by a thousand or no decimal points if you do not want it to be divisible.
Mandatory functions:
d. Total supply - this defines the total number of your tokens in circulation.
e. BalanceOf - this defines how many tokens an address has.
f. Transfer - this function takes tokens from the total supply and gives them to a user.
g. TransferFrom - this function can transfer tokens between any two users that have them.
h. Approve - this function verifies that your contract tokens can be given to a user taking the total supply into account.
i. Allowance - similar to Approve but it verifies that one user has enough tokens in their balance to send to someone else.
- What are the benefits of setting a token standard like ERC20? Promotes the growth of the Ethereum ecosystem, by providing a standard set of functions for smart contracts that can all interact with other ERC20 tokens on the network.
- What functions are in the ERC20 Token Standard Interface and what do they do?
totalSupply() - sets the fully diluted number of tokens
balanceOf() - retrieves the balance of tokens for any Ethereum address that interacts with the smart contract
1: having a standard is critical in order to build projects that are built on top of the ERC20. It also provides for framework so that each project doesnât have to reinvent the wheel.
2. ERC20 are turing complete token allowing different functions in the interface including whatifs, balances, . looping
- It makes it easier for wallets and exchanges to support the tokens. It also provides an easily repeatable process for developers so they donât have to recreate the token functions every time they create a new token.
totalSupply() - Returns the total token supply.
balanceOf() - returns the account balance of the designated account
transfer() - Transfer a specific amount to a specific address
- Every ERC20 token behaves the same way. For example, a wallet that supports ERC20 transfer can transfer every ERC20 token on ethereum.
- balanceOf() gives you an output of that ERC20 balance of the address.
transfer() transfer tokens from one address to another.
- What are the benefits of setting a token standard like ERC20?
This creates a standard for applications to work efficiently with each other. This prevents âfrictionâ when integrating tokens into systems such as exchanges and wallets and reduces the complexity for developers to create further smart contracts and new tokens due to the similarities in the foundational structure.
- What functions are in the ERC20 Token Standard Interface and what do they do?
// gets the total supply of the token
function totalSupply() constant returns (uint theTotalSupply);
// gets the balance of a particular address
function balanceOf(address _owner) constant returns (uint balance);
// adds a given number of tokens to a given address
function transfer(address _to, uint _value) returns (bool success);
// moves a given amount of tokens from one address to another
function transferFrom(address _from, address _to, uint _value) returns (bool success);
// authorizes a given address to remove an amount of tokens from the ownerâs address
function approve(address _spender, uint _value) returns (bool success);
// gets the number of tokens allowed to be transferred from one address by another address
function allowance(address _owner, address _spender) constant returns (uint remaining);
- What are the benefits of setting a token standard like ERC20?
Standards elps to grow the commmunity since a standard will let make the community easier to interact in a specific âstandardizedâ way". - What functions are in the ERC20 Token Standard Interface and what do they do?
Samples:
totalSupply() is the max number of tokens
balanceOf() gives the balance of an address/wallet
tranfer() allows for transfers of tokens
-
so applications and wallets that support ERC20 standards can use any ERC20 tokens for increased compatibility and efficiency
-
some of the functions include total balance, get balance of a particular account, and transfer functions.
What are the benefits of setting a token standard like ERC20?
Creates a common language which makes tokens more interoperable and offers ease of use between wallets. Offers developers an established platform to build upon instead of needing to create their own standard for their new token.
What functions are in the ERC20 Token Standard Interface and what do they do?
totalsupply shows total supply of token
balanceOf() shows balance of token hodlr address
transfer() sending tokens from one address to another
doSomething() execute instruction
transferFrom() take tokens from an address
allowance() indicates how many tokens authorized to be transfered
approve() address authorizes transfer
-
What are the benefits of setting a token standard like ERC20?
Ans: Frictionless economy => efficient economy. Not sure what else is a benefit. -
What functions are in the ERC20 Token Standard Interface and what do they do?
Ans: TotalSupply() for example. There is another function that returns the balance i.e. number of ETH coins remaining with a user.
-
What are the benefits of setting a token standard like ERC20?
All programmers could have a standardized way to create a token and these token could communicate easily. -
What functions are in the ERC20 Token Standard Interface and what do they do?
totalSupply() - gives total number of tokens in circulation
balanceOf() - queries the number of tokens held by a given address
transfer() - transfers a number of tokens directly from the message sender to another address
approve() - allows a token holder to withdraw certain number of tokens
transferFrom() - transfer certain amount of tokens from one address to another