Homework: ERC20

  1. All coins tokens can interact with each other.

2.totalSupply() - Total supply of tokens.
balanceOf() - Amount balance.
transfer()- Recipient of transaction.

1 Like
  1. So the code can follow the standard.
  2. balanceOf() gives the balance of the token in the account.
1 Like
  1. Setting standars such as ERC20 for the creation and interaction with a token sets a commom ground that facilitates the integration of this token with a more wide range of programms/applications across an ecossystem, expanding use cases and accelerating inovation around it. Similar to the importance of having programming standarts so the developer community can grow and create in more efficient, robust and creative ways, because there’s a common base-layer to participate, interact and collaborate to the ecossystem…
  2. Common functions to a ERC20 token are: balanceOf() - that provides the ammount of tokens held by a given address;, transfer() that gives the ability for this token to be transfered from an address to another; but usually for smart contract operations is useful the combination of allowance() - function provides the number of tokens allowed to be transferFrom() an address to another, including smart contract addresses.
    There is more to it, but those are main common functions you expect in an ERC20 token contract.
1 Like
  1. What are the benefits of setting a token standard like ERC20?
    That all developers are programming their code to certain requirements and making it efficient and easy for all users, dexs, platforms etc to easily see balance, owners etc.

  2. What functions are in the ERC20 Token Standard Interface and what do they do
    Totalsupply - total supply of holder
    BalanceOf - accepts address returns balance uint
    Allowance - gives allowance to user to spend tokens
    Approve - approve user to spend a certain amount of tokens
    Transfer - transfer tokens from - to
    Transferfrom - transfer tokens from, to, amount (needs approval)

1 Like
  1. What are the benefits of setting a token standard like ERC20?

It ensures there’s a frictionless coding economy. If everyone’s using the same language it’s easier to communicate.

  1. What functions are in the ERC20 Token Standard Interface and what do they do?

The totalSupply() function tells you how much total tokens exist.
The balanceOf(account address) gives you a balance of ERC20 tokens from a public address.
transfer() allows someone to transfer their ERC20 tokens to another public address.

1 Like
  1. The same structures allow for interoperability and efficiency creating a frictionless
    environment.
  2. balanceOf(): number of tokens held by a given address
    transfer(): send any number of tokens directly from sender to another address
    approve() and transferFrom(): a token holder can use approve() to allow a transfer
    of an allowance (certain number of tokens) to another address.
    allowance(): number of tokens that can be transferred from one designated
    address to another designated address
1 Like

ERC-20 has many benefits:

  • making it easy to create new tokens (cryptocurrencies)
  • allowing wallets to hold different tokens
  • creating a means for exchanges to list more tokens by providing nothing more than the address of the token’s contract
  • balanceOf() provides the number of tokens held by a given address.

  • transfer() sends a number of tokens directly from the message sender to another address. Note that there are no checks made on the recipient address, so it is incumbent on the sender to ensure that the recipient is as intended.

  • approve() programs tokens to be sent when a condition is met.

  • allowance() provides the number of tokens allowed to be transferred from a given address by another given address.

1 Like
  1. What are the benefits of setting a token standard like ERC20?
  • any project that builds with the standard will be compatible with exchanges and wallets that support the token standard
  1. What functions are in the ERC20 Token Standard Interface and what do they do?
  • There are several main functions of ERC20 token contracts, including transfer() which allows a user to send tokens to another user, approve() which gives approval to send up to a certain number of tokens to an address, transferFrom() which provides the address from which the approved allowance tokens can be transferred to an address, and allowance() which specifies the number of tokens that can be transferred using the transferFrom function.
1 Like
  1. All DApps, developers etc can inter communicate with each other in the same way.
  2. Total Supply - gives maximum number of tokens that exist
    Address Account - gives a public address balance of ERC20 tokens.
1 Like

What are the benefits of setting a token standard like ERC20?
ERC20 tokens provide a common standard to create tokens on the Ethereum Blockchain which makes communication and integration way easier.

What functions are in the ERC20 Token Standard Interface and what do they do?
The balanceOf() function provides the number of tokens held by a given address. Note that anyone can query any address’ balance, as all data on the blockchain is public.

The transfer() function transfers a number of tokens directly from the message sender to another address.

approve() and transferFrom() are two functions that allow the above scenario to work using a two-step process.

The allowance() function provides the number of tokens allowed to be transferred from a given address by another given address.

2 Likes
  1. Setting standards provides frictionless operation, integration and communication with each other within the code.
  2. Three of the main functions in the ERC20 standard code interface are:
    (a) function totalSupply() this would read the total supply available.
    (b) function balanceOf (address account) would provide the balance of the account
    © function transfers (address recipient,uint256 amount) would provide a transfer to and account.
1 Like

What are the benefits of setting a token standard like ERC20?
It allows all tokens built on that standard to be interoperable and communicate with each other frictionlessly

What functions are in the ERC20 Token Standard Interface and what do they do?

  1. BalanceOf - Gives the balance of a specific address
  2. transfer - Transfers coins from the sender address to another address
  3. allowance - Shows how many tokens are allowed to be transferred
  4. doSomething - Gives some instruction
  5. approve - Part of a 2 step process which authorizes to transfer an amount of tokens to another given address
2 Likes
  1. What are the benefits of setting a token standard like ERC20?

A// It defines how we all program , it makes communication and integration easier in the momento of creating tokens on the ethereum network.

  1. What functions are in the ERC20 Token Standard Interface and what do they do?

A// Function totalSupply(): it give you how many tokens are in circulation.
Function balanceOf(): To get the balance of the account.

1 Like
  1. ERC20 Standard allows all the tokens that are deployed on Ethereum Network to be able to operate and comunicate betwen eachother in a efficent and consistent manner.
  2. Total supply () function display how many tokens are in total circulation; Balance of ( address account) current balance
1 Like

Homework on ERC20 token standard.

  1. What are the benefits of setting a token standard like ERC20?
    It makes it easy for different exchanges and wallets to interact with all tokens deployed with ERC20

  2. What functions are in the ERC20 Token Standard Interface and what do they do?
    totalsupply() - tells the total supply of the token
    transfer() - transfers token from wallets to wallets
    balanceOf() - Tells the remaining token a wallet is holding.

1 Like
  1. The account model doesn’t require much space as the UTXO model, why is that a benefit? This means exchanges and wallets will support this standard

  2. How is the account model not as great as the UTXO model for privacy? Total supply of tokens- provides an exact amount of supplied tokens.
    Balance- provides the balance of a wallet

1 Like
  1. The benefits of setting a token standard like ERC20 are:
  • defines how we program tokens on the network
  • all tokens on the network can talk in the same way
    -provides efficiency
  • creates an efficient economy
  • promotes progress within such an economy
  1. totalSupply() = how many tokens in circulation

balanceOf(address account) = account balance

transfer(address recipient, unit256 amount) = This function lets the owner of the contract send a given amount of the token to another address just like a conventional cryptocurrency transaction.

allowance = allowance(address _owner, address _spender) constant returns (uint remaining); = shows how many tokens are allowed to be transferred

Screenshot 2022-10-31 at 19.07.11

1 Like

1 having a standard like ERC20 makes all the tokens easily compatible for different exchanges, wallets and dapps

2 totalsupply() lets you see the total supply of a token
balanceof() lets you see how many tokens a wallet is holding

1 Like
  1. Having a token standard like ERC20 has a lot of benefits, being the most important one the fact that there is a standard language that all the applications use and allows them to communicate with each other. It also allows wallets and exchanges to adopt the tokens easily. It is beneficial for the community, for the space and it significantly increases efficiency.

  2. There are a lot of different standard functions in the ERC20 standard (which is a standard for fungible tokens). The two examples given in the video are totalSupply() which gives you the total amount of tokens in circulation and the balanceOf(address account) function that gives you the balance of the specified address acount.

1 Like
  1. the standard token is of great advantage since the same protocol is to be used. This unites the language and makes everything compatible from day one between wallets and exchanges.
  2. totalSupply () check the maximum token that exist.
    balanceOf ( Address account) check specific addresses and ist total value.
1 Like