第一种:接口形式调用合约为什么采用这种方式? 原因是因为被调用合约过于复杂的时候,全引入进来的话没有必要! 被调用合约:// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; contract Counter { uint public count; function inc() external { count += 1; } function dec() external { count -= 1; } } 调用合约:// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; // 这个接口名称叫什么不重要,规范建议首字母大写 interface ICounter { function count() external view returns(uint); function inc() external; } contract Interface { uint public count; // _counter为被调用合约的地址 function examples(a...