Test token
unknown
java
2 years ago
539 B
18
Indexable
// SPDX-License-Identifier: MIT
pragma solidity 0.8.19;
import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
contract testToken is ERC20 {
constructor() ERC20("TestToken", "TTK") {
uint256 totalSupply = 500 * (10 ** uint256(decimals()));
_mint(msg.sender, totalSupply);
}
function burn(uint256 amount) external {
_burn(msg.sender, amount);
}
//Function to set decimals to 0
/**
function decimals() public pure override returns (uint8) {
return 0;
}
*/
}Editor is loading...