Created
November 15, 2020 14:53
-
-
Save iamonuwa/489d1ae0449004a20523fc53dbb36c0b to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: MIT | |
pragma solidity >=0.5.0 <0.8.0; | |
import 'https://github.com/OpenZeppelin/openzeppelin-contracts/contracts/token/ERC20/ERC20.sol'; | |
import 'https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/math/Math.sol'; | |
contract ExampleToken is ERC20 { | |
using SafeMath for uint256; | |
uint8 public constant DECIMALS = 18; | |
constructor () ERC20("EXAToken", "ETN") public {} | |
function mint(address to, uint amount) public returns (bool) { | |
_mint(to, amount); | |
return true; | |
} | |
function burn(address to, uint256 amount) public returns (bool) { | |
_burn(to, amount); | |
return true; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment