Skip to content

Instantly share code, notes, and snippets.

@Charlie-pang-sys
Charlie-pang-sys / tests...FundMe.sol
Created January 16, 2025 13:42
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.26+commit.8a97fa7a.js&optimize=false&runs=200&gist=
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;
import {AggregatorV3Interface} from "@chainlink/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol";
contract FundMe{
// 1、创建一个收款函数
// 2、记录投资人并且查看
// 3、在锁定期内,没有达到目标值,投资人在锁定期以后退款
mapping(address=>uint256) public fundersToAmount;
@Charlie-pang-sys
Charlie-pang-sys / test...FundMe.sol
Created January 8, 2025 14:35
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.26+commit.8a97fa7a.js&optimize=false&runs=200&gist=
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;
import {AggregatorV3Interface} from "@chainlink/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol";
contract FundMe{
mapping(address=>uint256) public fundersToAmount;
AggregatorV3Interface internal dataFeed;
uint256 MINIMUM_VALUE = 100 *10 **18;
constructor(){
dataFeed = AggregatorV3Interface(0x694AA1769357215DE4FAC081bf1f309aDC325306);
@Charlie-pang-sys
Charlie-pang-sys / test...FundMe.sol
Created January 8, 2025 14:01
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.26+commit.8a97fa7a.js&optimize=false&runs=200&gist=
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;
import {AggregatorV3Interface} from "@chainlink/contracts/src/v0.8/shared/interfaces/AggregatorV3Interface.sol";
contract FundMe{
mapping(address=>uint256) public fundersToAmount;
AggregatorV3Interface internal dataFeed;
uint256 MINIMUM_VALUE = 100 *10 **18;
constructor(){
dataFeed = AggregatorV3Interface(0x694AA1769357215DE4FAC081bf1f309aDC325306);
@Charlie-pang-sys
Charlie-pang-sys / test...FundMe.sol
Created January 8, 2025 13:39
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.26+commit.8a97fa7a.js&optimize=false&runs=200&gist=
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;
contract FundMe{
}
@Charlie-pang-sys
Charlie-pang-sys / test...FundMe.sol
Created January 8, 2025 13:35
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.26+commit.8a97fa7a.js&optimize=false&runs=200&gist=
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;