Description:
Smart contract deployed on Ethereum.
Blockchain: Ethereum
Source Code: View Code On The Blockchain
Solidity Source Code:
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.19;
contract SimpleBGS {
string public constant name = "BegusA Coin";
string public constant symbol = "BGS";
uint8 public constant decimals = 18;
uint256 public totalSupply;
mapping(address => uint256) public balanceOf;
address public owner;
event Transfer(address indexed from, address indexed to, uint256 value);
constructor() {
owner = msg.sender;
totalSupply = 1000000000 * 10 ** decimals;
balanceOf[msg.sender] = totalSupply;
emit Transfer(address(0), msg.sender, totalSupply);
}
function transfer(address to, uint256 value) external returns (bool) {
require(balanceOf[msg.sender] >= value, "Insufficient balance");
balanceOf[msg.sender] -= value;
balanceOf[to] += value;
emit Transfer(msg.sender, to, value);
return true;
}
}
Submitted on: 2025-10-24 15:41:11
Comments
Log in to comment.
No comments yet.