solidity/test/libsolidity/semanticTests/various/balance.sol
2023-05-11 10:56:55 -05:00

11 lines
211 B
Solidity

contract test {
constructor() payable {}
function getBalance() public returns (uint256 balance) {
return address(this).balance;
}
}
// ----
// constructor(), 23 wei ->
// getBalance() -> 23