Homework: ERC20

  1. What are the benefits of setting a token standard like ERC20?
    Setting standards improves efficiency and also helps easy swapping of ERC20 tokens. Also, becomes easier for developers, and other end users to follow the code in specific.

  2. What functions are in the ERC20 Token Standard Interface and what do they do?
    totalSupply : returns the total circulating amount of tokens
    balanceOf : returns how many tokens exist in an account

2 Likes
  1. Standard set of rules makes it easier for wallets and other infrastructure to communicate.
  2. totalSupply returns the number of coins/ tokens.
    balanceOf() shows the balance of an address.
    transfer() transfers money.
1 Like

1.) The token standards in the ERC-20 makes it possible for the tokens to be accepted on the ETH network and also make it so the tokens can communicate between one another, making the network more scalable.

2.) Some of the ERC-20 token functions are as follows.
TotalSupply() - gives the max # of tokens that exist.
BalanceOf(address account) - gives you the address balances of a token.
Transfer() - Transfers the token to another address.

1 Like
  1. What are the benefits of setting a token standard like ERC20?
    • This simplifies wallet support // exchange listings // n other interoperability topics
  2. 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
    • approve( ) - approves a transfer
    • transferFrom( ) - specifies account address to deduct executable funds from
    • allowance( ) - provides the amt of tokens to be transferred from an address
    • approval( ) - emits details of approvals of tokens from one address to another
1 Like
  1. What are the benefits of setting a token standard like ERC20?
    The benefits of a ERC20 token standard is that it allows for the same set of valuation rules to be made no matter what alternative currency system gets built on top of the Ehereum platform.
  2. What functions are in the ERC20 Token Standard Interface and what do they do?
    The standard functions in ERC20 include (but are not limited to) the following:
    totalSupply: returns the number of all tokens allocated by a given contract regardless of owner
    balanceOf: returns the current token balance of an account, identified by its owner’s address
    transfer: moves a specified amount of tokens from the owner’s balance to that of another user
    approve: returns the current approved number of tokens by an owner to a specific delegate
2 Likes
  1. What are the benefits of setting a token standard like ERC20?
    It allows any erc 20 token to communicate with the current infrastructure and make use of it. It increases efficiency and collaboration.

  2. What functions are in the ERC20 Token Standard Interface and what do they do?
    transfer():
    balanceOf():
    approve():

  1. ERC20 token standard provides common set of features and interfaces for token contracts made in Ethereum block chain. Some of the benefits it has are 1. It allows wallets to provide token balances for multiple contracts. 2. Exchanges can list more tokens by just providing the address of token contracts.

  2. Function: Balance0f() : It provides the number of tokens held by an address holder.
    Function: Trsnsfer(): It transfer number of tokens from sender to receiver address.
    Function: doSomething(): It allows a contract maker to do something (eg. new token contract) on the blockchain.
    Function: approve(): with this function an address holder can approve another address to take upto a number of tokens called allowance.

Function: TransferFrom(): with this function and address can take a number of tokens from another address if approved.

1 Like

Using a standard like ERC20 has multiple benefits such as all tokens speaking the same coding language, reusing functions that have previously been made, and has the fastest transaction times compared to other coins.

The following are a review of the functions within the ERC20 Token Standard Interface:

  • balanceOf() - Shows the balance of the account in the argument. Can be done for any account as the information is publically available on the blockchain.

  • transfer() - Transfers a certain amount of the ERC20 token to another user. Not a great function to send to a smart contract.

  • approve() - Provides information to allow a transfer of tokens to a smart contract.

  • transferFrom() - Allows a smart contract to transfer the tokens from the owner of the smart contract to the recipient.

  • totalSupply() - Allows for a calculation of the total supply of the token.

  • allowance() - Provides the number of tokens that allowed to be transferred by one address to another.

Here’s a link that goes in better detail about the functions.

1 Like

Homework on ERC20 token standard.

  1. What are the benefits of setting a token standard like ERC20?
    – Setting standards like ERC20 provides a consistent way (features and interfaces) for any wallet or exchange to talk to a class of tokens built on a particular platform such as the Ethereum Smart Contract platform

  2. What functions are in the ERC20 Token Standard Interface and what do they do?
    – The ERC20 Token Standard Interface includes function such as:
    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
    approve() - allows the token holder to give another address (usually of a smart contract) approval to transfer up to a certain number of tokens, known as an allowance.
    transferFrom() used to provide the allowance
    allowance() function 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?
  2. What functions are in the ERC20 Token Standard Interface and what do they do?
  1. The benefits are that all token created with the same set of functions allows to talk to each other, and wallets and exchanges will be able to support the tokens fairly easily.
    function totalSupply(): It sets up the total supply.
    function balanceOf(address account): It gets the balance of token owner
1 Like

It increases efficiency and allows Token to operate on platforms and wallets seamlessly.

totalSupply (provide information about the total token supply)

balanceOf (provide account balance of the owner’s account)

transfer (execute transfer of a specified number of tokens to a specified address)

transferFrom (execute transfer of a specified number of tokens from a specified address)

approve (allow a spender to withdraw a set number of tokens from a specified account)

allowance (return a set number of tokens from a spender to the owner)

1 Like
  1. Takes advantage of network effect and creates a more efficient network ecosystem.
  2. totalsupply- designates total token supply, balanceOf- shows wallet address balance, transfer- allows funds to be sent from one address to another
1 Like

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

Hello sir, did you forgot to type your descriptions?

If you have any more questions, please let us know so we can help you! :slight_smile:

Carlos Z.

  1. all exchanges etc, speak the same “language” for ease of support like balance,
  2. standardized functions, they provide include: balance, transfer etc. (Balance) provides the balance. (Transfer) would provide the details of the movement of tokens from one address to another.
1 Like

Homework on ERC20 token standard.

  1. What are the benefits of setting a token standard like ERC20?
    It is easy for exchanges and wallets to accept all ERC 20 tokens from day 1 instead of wasting time to figure out each token one at a time
  2. What functions are in the ERC20 Token Standard Interface and what do they do?
    Totalsupply() – show total supply
    balanceOf (address account) – display an eth address balances
    transfer() – send tokens
1 Like
  1. ERC20 tokens have the benefit that all tokens based on the same standards it enables wallets and exchanges to easily implement a new token that is built on a standard that is common knowledge and true for all ERC20 tokens.

  2. TotalSupply(): Maximum number of tokens that exist.
    BalanceOf(address): A public addresses’ balance of ERC20 tokens
    Transfer(): Allows transfer of their ERC20 tokens to another public address
    DoSomething(): Operates instructions.
    Allowance(): Provides the number of tokens allowed to be transferred from a given address by another.
    Approve(): Numbers of tokens allowed to be transferred.

1 Like

The main benefits of setting token standards such as ERC20 are that the standard creates rules and defines how we can program new tokens in exactly the same way, and also so they are deployed in the same fashion. This introduces compatibility. The comparability factor makes it possible to create new currencies and nfts that can interact on the same network without confusion. This innovation has, for example made it possible to nnot only create new currencies and non fungible tokens, but also to have them listed frictionlessly on exchanges. This quality also allows for a simple integration of the new token into wallets by simply providing the smart contract address.
ERC token standards supply a variety of built in functions that are very useful in the construction and functionality of the smart contract. For example, the balanceOf () function allows anyone querying on the chain to retrieve the balance of any ethereum address. This enables the contract to see if the sender or recipient actually has enough funds to execute the conditions of the contract. the transferFrom () function elicits the actual transaction of the funds once the contract details are executed, although this funtion is limited only to sending from one address to one other address. For more complex transactions, doSomething () allows for the user to call for a specific task, and uses allowances to set a limit on how much the transaction can incur.Furthermore, transferFrom( () allows for the contract to take an allowed number of tokens from an account to execute its work. The allowance () function creates the ability to to set a specific number of tokens to taken from one address to another address. Finally, the approval () function makes possible the emission of the actual specific tokens that were transacted between two accounts. This function is the final event of the smart contract and is the function that provides the ability to balance the ledgers and keep the balances correct

1 Like
  1. Setting a standard is important in order to allow exchanges, wallets and all entities that would be able to support such token, to do in the same “standard” way. In fact as soon as a new ERC-20 token comes out it can be handle by all entities that already support such standard, without having to integrate with it in a new way.
  2. There are several functions that ca be used in the ERC20 Token Standard Interface. One is balanceOf() says the number of token held by a given address (everyone can do it since all data in the blockchain are public). Transfer() is a function that simply transfer a certain specified number of token from one address to another. Other functions are more related with the functionality of the smart contract, like doSomething() that act or not based on allowed token (that has to previously provide using approve() funciton).
1 Like
  1. Standards make it much easier for apps like Wallets to know how to read the code of ANY ERC20 token

  2. totalSupply = total available supply of the token
    balanceOf (address account) = How much of said token you have in your Wallet

1 Like
  1. Everyone can build using the same commands and therefore all the “apps” and other programs will in some way be compatible with each other.

  2. balanceOf(x) gives the balance of a wallet,
    totalsupply(x) gives the total supply of the ERC20 token,
    transfer(x) transfers token to another wallet

1 Like