Homework: ERC20

  1. It enables communication between tokens and wallets by setting standards

  2. totalSupply(): gives maximum number of tokens that exist
    balanceOf(address): gives 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.

1 Like
  1. What are the benefits of setting a token standard like ERC20?
  • The ERC20 standard uses the same functions. This way it is easier to adopt new tokens for wallets, exchanges etc.
  1. What functions are in the ERC20 Token Standard Interface and what do they do?
  • The balanceOf() function outputs the balance of the input address
  • The transfer() function outputs the funds to the input address with the amount
  • The totalSupply() function outputs the total supply number of the input token
  • The approve() function outputs the approval for the input address to spend from your account
  • The transferFrom() function outputs a transfer from the three inputs; senders address, receivers address & amount of tokens
  • The allowence() function outputs the amount of tokens allowed to spend for the input address
1 Like

This standard is accepted by most wallets and exchanges.

balanceOf() is used to check the balance of an account. transfer() is used to send an amount from on account to another. totalsupply is another function that gives the total amount of tokens that exist.

1 Like
  • What are the benefits of setting a token standard like ERC20?
  • What functions are in the ERC20 Token Standard Interface and what do they do?
  1. Standards increase toke interoperability and reduce friction.

  2. Some ERC20 programming standards are;
    function totalSupply() – returns the total supply of a token
    function balanceOf(address tokenOwner) — returns the balance of the address
    function allowance(address tokenOwner, address spender) — returns the number of tokens that the address can transfer
    function transfer(address to, uint tokens) — transfers tokens to a address
    function approve(address spender, uint tokens) — gives a address the approval to transfer funds
    function transferFrom(address from, address to, uint tokens) — transfers tokens from a address.

2 Likes
  • What are the benefits of setting a token standard like ERC20?
    Easily communicate with various other smart contracts having different use cases and every contract may have different standards, makes it deploy-able, interoperable and efficient. Economy becomes efficient when we do not have friction, that’s why we need standards.

  • What functions are in the ERC20 Token Standard Interface and what do they do?
    function totalSupply() - All wallets, exchanges, ERC tokens know it will have totalSupply function as its the standard and can’t be named anything else.
    function balanceOf(address account) - returns the balance of the address
    function transfer(address recipient, uint256 amount) - transfers/receives tokens

1 Like

1- ERC20 is a standardized, fungible token format used on the ETH blockchain. It is formatted for commonality so that different users can adopt or adapt to a particular token by way of standardization

ERC 721 & 155 are NFT (non fungible) versions of an ERC token, commonly used in gaming.

2- ERC20 functions are common (standardized) instructions used in the language (programming) of an ERC20 token. This allows the shared use and transfer of ERC20 tokens between users and common platforms.

Some examples include: totalSupply(), transfer(), approve(), transferFrom(), allowance(), balanceOf()

Question:
What alternative uses are there for NFT’s other than gaming are there? Could you give an example?

1 Like

Q1: Benefits of setting token standards like ERC20 is to lay the framework of friction-less interoperability between programmers, platforms, exchanges, wallets and users on specific networks. In the case of Ethereum this is the ERC20 standard.

Q2: Functions of the ERC20 Token Standard Interface are;

balanceOf() ---- offers quering and balance of token held by a given address
transfer() -------- allows sending token to another address
allowance() ----- provides the number of tokens allowed to be transferred from an address
approve() ----- provides how many tokens can be used to run a smart contract
transferFrom() — provides an address of where tokens are being sent from

1 Like

1) What are the benefits of setting a token standard like ERC20?
It’s important to have standards bcuz without them, everyone would be building their own versions and that would be a nightmare for wallets and exchanges to figure out how to talk differently to all these tokens. Without standards we couldn’t build applications that could talk to each other. So, ERC20 is the standard in how we program these tokens on the Ethereum network to operate and integrate with each other.

2) What functions are in the ERC20 Token Standard Interface and what do they do?
Here are a couple that Ivan mentioned:

function totalSupply()
Each ERC token will have the totalSupply function. It tells you how many tokens are in the total supply.

function balanceOf(address account)
When exchanges or wallets want to check how much balance you have they will use this.

1 Like
  1. by setting a standard this allows all dapps and tokens to be created with the same rules and guidelines. This enables a certain standard throughout the market and also is recognised within the industry. Multiple exchanges also accept erc-20 which is good news for you the developer as this will help gain more exposure.

total supply - maximum supply of tokens in existence.
balance - enables account holder to view their total holdings,
transfer - the transfer from one wallet to another.

  1. Because all tokens using the same functions meaning they can communicate the same way and that is very effective.

totalsupply - the sum of all balances
balanceOf () - returns the balance of an address.
transfer() - send a certain number of tokens from sender to the recipient.
approve() - token holder gives approval to another address to transfer certain amount of tokens.

and more…

1 Like
  1. What are the benefits of setting a token standard like ERC20?
    Setting a standard makes it easier to have tokens integrated onto wallets which is efficient.

  2. What functions are in the ERC20 Token Standard Interface and what do they do?
    There are functions such as Total Supply which sets the number of tokens, BalanceOf which helps us check balances, and a transfer function for sending to different address’.

1 Like
  1. When you have a standard in which everyone’s token can communicate it allows wallets, exchanges etc connect to one another limiting friction in the system and allowing scalability.

  2. Totalsupply () gives max number of token that exist.

BalanceOf- when given an address it returns the account balance of that address.

approve(): someone who holds tokens gives another address approval to transfer an x amount of tokens(allowance).

allowance(): tell the number of tokens allowed to be transferred from a given address of another.

doSomething(): to operate instructions.

1 Like

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

Yes sir, but could you please describe what those functions do?

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

Carlos Z.

NFTs work essentially as a database entry for any type of good.

Collectibles

Paintings and sculptures could be verified and authenticated by experts before creating a non-fungible token for a given piece of art.

Online Gaming

Often, characters in games acquire tradeable items like weapons, clothing, and even property.

Tickets

If I have a ticket to see Barcelona play Manchester United and you have a ticket to your local high school basketball game, those are both similar items, but they have wildly different values.

Identity & Certification

You could receive a nontradable digital token as your birth certificate, as your passport, and as your driver’s license.

Hope this gives you a clear view of the subject, keep learning! :slight_smile:

If you have any doubt, please let us know so we can help you!

Carlos Z.

2 Likes

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

It sets a standard for all programming language to adhere to which , ultimately, creates greater efficiency within the Ethereum network. It will make it much easier for a variety of programs, tokens, etc., to inter-operate with each other. For example, wallets wont be confused by a variety of tokens that are programmed differently and possibly do not know how to handle each token properly.

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

Functions that I noticed included:
Total Supply - what’s the total count of tokens minted?
Balance - what’s the current balance of tokens?
Transfer - the act of exchanging tokens from one user to another (I assume)

1 Like
  1. Setting a tokens standard like the ERC20 provides better guidelines how tokens functions and interact with others. Better wallet experience in terms of balance and exchanges using simple addresses but yet secure for listings of many token contracts.
  2. The ERC20 token standard interface shows balanceOf() and transfer() that can perform sending tokens from one wallet address to another. It also perform transfering token to dead address for burning as well as other symbols use to work on smart contract.
1 Like
  1. The ERC20 standard allows for applications to be built that can communicate with the tokens. This propels the development of applications and adoption of Ethereum.

  2. Functions in the ERC20 Token Standard allow users to interact with the smart contract of that token. Some functions allows users to find the balance of an account and transfer funds from one account to another. For Example:

    • balanceOf() function returns the number of tokens held by a particular address.
    • transfer() function transfers a number of tokens directly from the message sender to another address.
    • allowance() function provides the number of tokens allowed to be transferred from a given address by another given user.
1 Like

Brilliant and complete answer!

That clears it up completely for me. That’s probably one of the most useful applications of the token system.

Cheers :pray:

2 Likes

1: It creates a universal language that makes it much easier for exchanges and wallets to adopt a new coin.

2: totalSupply() - shows the total supply of a token
balanceOf() - shows the balance of a token hodler
transfer() - can transfer your tokens to a given address.
etc.

1 Like
  1. What are the benefits of setting a token standard like ERC20?
    Reduces administrative friction as updates will be accepted across all tokens. It allows wallets to hold multiple coins.
  2. What functions are in the ERC20 Token Standard Interface and what do they do?
    totalSupply() maximum number of existing tokens
    balanceOf() balance of tokens in a public address
    transfer() allows transfer of tokens to a public address
    allowance() maximum number of tokens owner approves to be transferred to spender’s account
    approve() owner allows a specific number of tokens to be transferred to spender account
1 Like