Closed zhfnjust closed 2 years ago
contract C { uint immutable maxBalance; constructor(address _reference) { // Assignments to immutables can even access the environment. maxBalance = _reference.balance; } function isBalanceTooHigh(address _other) public view returns (bool) { return _other.balance > maxBalance; } }