I'm trying to ask to a smart contract the balance of it. The code for obtain the balance in Solidity is this:
function balance() external view returns (uint) {
uint amount = address(this).balance;
return amount;
}
Unfortunately when I run the code what I obtain is a block as result:
What I'm doing wrong?