Source Code
Overview
ETH Balance
0.000010003 ETH
ETH Value
$0.03 (@ $3,098.53/ETH)
Cross-Chain Transactions
Loading...
Loading
Contract Source Code Verified (Exact Match)
Contract Name:
GuessTwoThirdsGame
Compiler Version
v0.8.28+commit.7893614a
Optimization Enabled:
No with 200 runs
Other Settings:
paris EvmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX‑License‑Identifier: MIT
pragma solidity ^0.8.19;
import "@openzeppelin/contracts/security/ReentrancyGuard.sol";
/**
* @title GuessTwoThirdsGame
* @notice A blockchain implementation of the “two‑thirds of the average” game.
*
* – Each unique address may join once per round by sending any positive amount of ETH.
* – When the pseudo‑random stop condition is hit, the player whose guess is
* closest to ⌊2 / 3 × average⌋ wins the entire prize pool, minus a 1 % fee for the owner.
* – If several players are equally close, the earliest participant wins.
*
* @dev The minimum/maximum early‑stop threshold (`minX`, `maxX`) is chosen
* once at deployment, so the game designer can decide how quickly a
* round is expected to finish (e.g. 2–3 players, 5–10 players, etc.).
*/
contract GuessTwoThirdsGame is ReentrancyGuard {
/* --------------------------------------------------------------------- */
/* Data Types */
/* --------------------------------------------------------------------- */
struct Player {
address addr;
uint256 amount;
}
/* --------------------------------------------------------------------- */
/* State Variables */
/* --------------------------------------------------------------------- */
Player[] public players; // List of current‑round players
mapping(address => bool) public hasPlayed;
uint256 public totalAmount; // Total ETH in current round
uint256 public gameId; // Incremented after every round
address public immutable owner; // Fee receiver (1 %)
uint256 public immutable minX; // Lower bound for stop threshold
uint256 public immutable maxX; // Upper bound for stop threshold
/* --------------------------------------------------------------------- */
/* Events */
/* --------------------------------------------------------------------- */
event PlayerJoined(address indexed player, uint256 amount);
event GameEnded(
uint256 indexed gameId,
address indexed winner,
uint256 reward,
uint256 guessTarget
);
/* --------------------------------------------------------------------- */
/* Constructor */
/* --------------------------------------------------------------------- */
/**
* @param _minX The smallest possible early‑stop threshold (≥ 1).
* @param _maxX The largest possible early‑stop threshold (≥ _minX).
*
* Example: _minX=2, _maxX=3 ⇒ the game may stop after 2 or 3 players,
* giving an expected total of ~6–9 participants.
*/
constructor(uint256 _minX, uint256 _maxX) {
require(_minX > 0, "minX must be positive");
require(_maxX >= _minX, "maxX must be >= minX");
owner = msg.sender;
gameId = 1;
minX = _minX;
maxX = _maxX;
}
/* --------------------------------------------------------------------- */
/* Game Interface */
/* --------------------------------------------------------------------- */
/**
* @notice Join the current round by sending ETH.
* @dev `nonReentrant` prevents re‑entrancy attacks.
*/
function play() external payable nonReentrant {
require(!hasPlayed[msg.sender], "You already played");
require(msg.value > 0, "Must send ETH > 0");
// Store participation
players.push(Player(msg.sender, msg.value));
hasPlayed[msg.sender] = true;
totalAmount += msg.value;
emit PlayerJoined(msg.sender, msg.value);
// Possibly end the game
if (_shouldEndGame(players.length)) {
_endGame();
}
}
/* --------------------------------------------------------------------- */
/* Internal Game Logic */
/* --------------------------------------------------------------------- */
/**
* @dev Pseudo‑random stop condition.
* Picks x ∈ [minX, maxX]. The round cannot end before x players
* have joined, and the actual end is decided randomly afterwards.
*/
function _shouldEndGame(uint256 n) internal view returns (bool) {
// Draw x in the inclusive interval [minX, maxX]
uint256 x = minX +
(uint256(
keccak256(
abi.encodePacked(block.prevrandao, block.timestamp, n)
)
) % (maxX - minX + 1));
if (n < x) return false; // Too early to end
// Second random check to decide whether to stop exactly at n players
uint256 l = n > x ? n - x : 1; // Lower bound
uint256 r = n + x; // Upper bound
uint256 y = l +
(uint256(
keccak256(
abi.encodePacked(blockhash(block.number - 1), msg.sender)
)
) % (r - l + 1));
return y == n;
}
/**
* @dev Determines the winner, distributes prize & fee, and resets state.
*/
function _endGame() internal {
uint256 average = totalAmount / players.length;
uint256 target = (average * 2) / 3; // ⌊2/3 × average⌋
// Earliest player wins ties
address winner = players[0].addr;
uint256 closestDiff = _absDiff(players[0].amount, target);
for (uint256 i = 1; i < players.length; ++i) {
uint256 diff = _absDiff(players[i].amount, target);
if (diff < closestDiff) {
winner = players[i].addr;
closestDiff = diff;
}
}
uint256 fee = totalAmount / 100; // 1 % fee
uint256 prize = totalAmount - fee;
// Payouts (use call to forward all remaining gas)
(bool okWinner, ) = payable(winner).call{value: prize}("");
require(okWinner, "Prize transfer failed");
(bool okOwner, ) = payable(owner).call{value: fee}("");
require(okOwner, "Fee transfer failed");
emit GameEnded(gameId, winner, prize, target);
// Reset state for next round
for (uint256 i = 0; i < players.length; ++i) {
hasPlayed[players[i].addr] = false;
}
delete players;
totalAmount = 0;
++gameId;
}
/* --------------------------------------------------------------------- */
/* Pure / View Utilities */
/* --------------------------------------------------------------------- */
function _absDiff(uint256 a, uint256 b) private pure returns (uint256) {
return a > b ? a - b : b - a;
}
/* --------------------------------------------------------------------- */
// Accept ETH sent directly to the contract
receive() external payable {}
}// SPDX-License-Identifier: MIT
// OpenZeppelin Contracts (last updated v4.9.0) (security/ReentrancyGuard.sol)
pragma solidity ^0.8.0;
/**
* @dev Contract module that helps prevent reentrant calls to a function.
*
* Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier
* available, which can be applied to functions to make sure there are no nested
* (reentrant) calls to them.
*
* Note that because there is a single `nonReentrant` guard, functions marked as
* `nonReentrant` may not call one another. This can be worked around by making
* those functions `private`, and then adding `external` `nonReentrant` entry
* points to them.
*
* TIP: If you would like to learn more about reentrancy and alternative ways
* to protect against it, check out our blog post
* https://blog.openzeppelin.com/reentrancy-after-istanbul/[Reentrancy After Istanbul].
*/
abstract contract ReentrancyGuard {
// Booleans are more expensive than uint256 or any type that takes up a full
// word because each write operation emits an extra SLOAD to first read the
// slot's contents, replace the bits taken up by the boolean, and then write
// back. This is the compiler's defense against contract upgrades and
// pointer aliasing, and it cannot be disabled.
// The values being non-zero value makes deployment a bit more expensive,
// but in exchange the refund on every call to nonReentrant will be lower in
// amount. Since refunds are capped to a percentage of the total
// transaction's gas, it is best to keep them low in cases like this one, to
// increase the likelihood of the full refund coming into effect.
uint256 private constant _NOT_ENTERED = 1;
uint256 private constant _ENTERED = 2;
uint256 private _status;
constructor() {
_status = _NOT_ENTERED;
}
/**
* @dev Prevents a contract from calling itself, directly or indirectly.
* Calling a `nonReentrant` function from another `nonReentrant`
* function is not supported. It is possible to prevent this from happening
* by making the `nonReentrant` function external, and making it call a
* `private` function that does the actual work.
*/
modifier nonReentrant() {
_nonReentrantBefore();
_;
_nonReentrantAfter();
}
function _nonReentrantBefore() private {
// On the first call to nonReentrant, _status will be _NOT_ENTERED
require(_status != _ENTERED, "ReentrancyGuard: reentrant call");
// Any calls to nonReentrant after this point will fail
_status = _ENTERED;
}
function _nonReentrantAfter() private {
// By storing the original value once again, a refund is triggered (see
// https://eips.ethereum.org/EIPS/eip-2200)
_status = _NOT_ENTERED;
}
/**
* @dev Returns true if the reentrancy guard is currently set to "entered", which indicates there is a
* `nonReentrant` function in the call stack.
*/
function _reentrancyGuardEntered() internal view returns (bool) {
return _status == _ENTERED;
}
}{
"evmVersion": "paris",
"optimizer": {
"enabled": false,
"runs": 200
},
"outputSelection": {
"*": {
"*": [
"evm.bytecode",
"evm.deployedBytecode",
"devdoc",
"userdoc",
"metadata",
"abi"
]
}
},
"libraries": {}
}Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
Contract ABI
API[{"inputs":[{"internalType":"uint256","name":"_minX","type":"uint256"},{"internalType":"uint256","name":"_maxX","type":"uint256"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"gameId","type":"uint256"},{"indexed":true,"internalType":"address","name":"winner","type":"address"},{"indexed":false,"internalType":"uint256","name":"reward","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"guessTarget","type":"uint256"}],"name":"GameEnded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"player","type":"address"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"}],"name":"PlayerJoined","type":"event"},{"inputs":[],"name":"gameId","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"hasPlayed","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"maxX","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"minX","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"play","outputs":[],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"uint256","name":"","type":"uint256"}],"name":"players","outputs":[{"internalType":"address","name":"addr","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"stateMutability":"payable","type":"receive"}]Contract Creation Code
60e060405234801561001057600080fd5b506040516115f73803806115f78339818101604052810190610032919061014e565b60016000819055506000821161007d576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610074906101eb565b60405180910390fd5b818110156100c0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016100b790610257565b60405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff1660808173ffffffffffffffffffffffffffffffffffffffff168152505060016004819055508160a081815250508060c081815250505050610277565b600080fd5b6000819050919050565b61012b81610118565b811461013657600080fd5b50565b60008151905061014881610122565b92915050565b6000806040838503121561016557610164610113565b5b600061017385828601610139565b925050602061018485828601610139565b9150509250929050565b600082825260208201905092915050565b7f6d696e58206d75737420626520706f7369746976650000000000000000000000600082015250565b60006101d560158361018e565b91506101e08261019f565b602082019050919050565b60006020820190508181036000830152610204816101c8565b9050919050565b7f6d617858206d757374206265203e3d206d696e58000000000000000000000000600082015250565b600061024160148361018e565b915061024c8261020b565b602082019050919050565b6000602082019050818103600083015261027081610234565b9050919050565b60805160a05160c0516113356102c26000396000818161020f01526105b00152600081816104bd0152818161058f015261061d015260008181610233015261093201526113356000f3fe60806040526004361061007f5760003560e01c806393e84cd91161004e57806393e84cd914610149578063c323400c14610153578063d7c81b551461017e578063f71d96cb146101a957610086565b80631a39d8ef1461008b57806332d0bbe3146100b657806370d20d3e146100f35780638da5cb5b1461011e57610086565b3661008657005b600080fd5b34801561009757600080fd5b506100a06101e7565b6040516100ad9190610bf8565b60405180910390f35b3480156100c257600080fd5b506100dd60048036038101906100d89190610c76565b6101ed565b6040516100ea9190610cbe565b60405180910390f35b3480156100ff57600080fd5b5061010861020d565b6040516101159190610bf8565b60405180910390f35b34801561012a57600080fd5b50610133610231565b6040516101409190610ce8565b60405180910390f35b610151610255565b005b34801561015f57600080fd5b506101686104bb565b6040516101759190610bf8565b60405180910390f35b34801561018a57600080fd5b506101936104df565b6040516101a09190610bf8565b60405180910390f35b3480156101b557600080fd5b506101d060048036038101906101cb9190610d2f565b6104e5565b6040516101de929190610d5c565b60405180910390f35b60035481565b60026020528060005260406000206000915054906101000a900460ff1681565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b61025d610539565b600260003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16156102ea576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016102e190610de2565b60405180910390fd5b6000341161032d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161032490610e4e565b60405180910390fd5b600160405180604001604052803373ffffffffffffffffffffffffffffffffffffffff16815260200134815250908060018154018082558091505060019003906000526020600020906002020160009091909190915060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506020820151816001015550506001600260003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff02191690831515021790555034600360008282546104409190610e9d565b925050819055503373ffffffffffffffffffffffffffffffffffffffff167f3330a6773675f31f62070870f40379f8c6d42e3761410011a4dfc42b18043d2f3460405161048d9190610bf8565b60405180910390a26104a3600180549050610588565b156104b1576104b0610702565b5b6104b9610b3c565b565b7f000000000000000000000000000000000000000000000000000000000000000081565b60045481565b600181815481106104f557600080fd5b90600052602060002090600202016000915090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060010154905082565b60026000540361057e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161057590610f1d565b60405180910390fd5b6002600081905550565b60008060017f00000000000000000000000000000000000000000000000000000000000000007f00000000000000000000000000000000000000000000000000000000000000006105d99190610f3d565b6105e39190610e9d565b4442856040516020016105f893929190610f92565b6040516020818303038152906040528051906020012060001c61061b9190610ffe565b7f00000000000000000000000000000000000000000000000000000000000000006106469190610e9d565b90508083101561065a5760009150506106fd565b600081841161066a576001610677565b81846106769190610f3d565b5b9050600082856106879190610e9d565b90506000600183836106999190610f3d565b6106a39190610e9d565b6001436106b09190610f3d565b40336040516020016106c39291906110a2565b6040516020818303038152906040528051906020012060001c6106e69190610ffe565b836106f19190610e9d565b90508581149450505050505b919050565b600060018054905060035461071791906110ce565b90506000600360028361072a91906110ff565b61073491906110ce565b90506000600160008154811061074d5761074c611141565b5b906000526020600020906002020160000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905060006107b3600160008154811061079b5761079a611141565b5b90600052602060002090600202016001015484610b46565b90506000600190505b60018054905081101561085c5760006107fa600183815481106107e2576107e1611141565b5b90600052602060002090600202016001015486610b46565b905082811015610850576001828154811061081857610817611141565b5b906000526020600020906002020160000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1693508092505b508060010190506107bc565b506000606460035461086e91906110ce565b90506000816003546108809190610f3d565b905060008473ffffffffffffffffffffffffffffffffffffffff16826040516108a8906111a1565b60006040518083038185875af1925050503d80600081146108e5576040519150601f19603f3d011682016040523d82523d6000602084013e6108ea565b606091505b505090508061092e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161092590611202565b60405180910390fd5b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1684604051610974906111a1565b60006040518083038185875af1925050503d80600081146109b1576040519150601f19603f3d011682016040523d82523d6000602084013e6109b6565b606091505b50509050806109fa576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109f19061126e565b60405180910390fd5b8573ffffffffffffffffffffffffffffffffffffffff166004547f64e67454795640f66cef8019a707b9381952f2f1024a355d5470bafc82af1800858a604051610a4592919061128e565b60405180910390a360005b600180549050811015610b055760006002600060018481548110610a7757610a76611141565b5b906000526020600020906002020160000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff021916908315150217905550806001019050610a50565b5060016000610b149190610b75565b6000600381905550600460008154610b2b906112b7565b919050819055505050505050505050565b6001600081905550565b6000818311610b60578282610b5b9190610f3d565b610b6d565b8183610b6c9190610f3d565b5b905092915050565b5080546000825560020290600052602060002090810190610b969190610b99565b50565b5b80821115610bdb57600080820160006101000a81549073ffffffffffffffffffffffffffffffffffffffff0219169055600182016000905550600201610b9a565b5090565b6000819050919050565b610bf281610bdf565b82525050565b6000602082019050610c0d6000830184610be9565b92915050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000610c4382610c18565b9050919050565b610c5381610c38565b8114610c5e57600080fd5b50565b600081359050610c7081610c4a565b92915050565b600060208284031215610c8c57610c8b610c13565b5b6000610c9a84828501610c61565b91505092915050565b60008115159050919050565b610cb881610ca3565b82525050565b6000602082019050610cd36000830184610caf565b92915050565b610ce281610c38565b82525050565b6000602082019050610cfd6000830184610cd9565b92915050565b610d0c81610bdf565b8114610d1757600080fd5b50565b600081359050610d2981610d03565b92915050565b600060208284031215610d4557610d44610c13565b5b6000610d5384828501610d1a565b91505092915050565b6000604082019050610d716000830185610cd9565b610d7e6020830184610be9565b9392505050565b600082825260208201905092915050565b7f596f7520616c726561647920706c617965640000000000000000000000000000600082015250565b6000610dcc601283610d85565b9150610dd782610d96565b602082019050919050565b60006020820190508181036000830152610dfb81610dbf565b9050919050565b7f4d7573742073656e6420455448203e2030000000000000000000000000000000600082015250565b6000610e38601183610d85565b9150610e4382610e02565b602082019050919050565b60006020820190508181036000830152610e6781610e2b565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000610ea882610bdf565b9150610eb383610bdf565b9250828201905080821115610ecb57610eca610e6e565b5b92915050565b7f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00600082015250565b6000610f07601f83610d85565b9150610f1282610ed1565b602082019050919050565b60006020820190508181036000830152610f3681610efa565b9050919050565b6000610f4882610bdf565b9150610f5383610bdf565b9250828203905081811115610f6b57610f6a610e6e565b5b92915050565b6000819050919050565b610f8c610f8782610bdf565b610f71565b82525050565b6000610f9e8286610f7b565b602082019150610fae8285610f7b565b602082019150610fbe8284610f7b565b602082019150819050949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600061100982610bdf565b915061101483610bdf565b92508261102457611023610fcf565b5b828206905092915050565b6000819050919050565b6000819050919050565b61105461104f8261102f565b611039565b82525050565b60008160601b9050919050565b60006110728261105a565b9050919050565b600061108482611067565b9050919050565b61109c61109782610c38565b611079565b82525050565b60006110ae8285611043565b6020820191506110be828461108b565b6014820191508190509392505050565b60006110d982610bdf565b91506110e483610bdf565b9250826110f4576110f3610fcf565b5b828204905092915050565b600061110a82610bdf565b915061111583610bdf565b925082820261112381610bdf565b9150828204841483151761113a57611139610e6e565b5b5092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600081905092915050565b50565b600061118b600083611170565b91506111968261117b565b600082019050919050565b60006111ac8261117e565b9150819050919050565b7f5072697a65207472616e73666572206661696c65640000000000000000000000600082015250565b60006111ec601583610d85565b91506111f7826111b6565b602082019050919050565b6000602082019050818103600083015261121b816111df565b9050919050565b7f466565207472616e73666572206661696c656400000000000000000000000000600082015250565b6000611258601383610d85565b915061126382611222565b602082019050919050565b600060208201905081810360008301526112878161124b565b9050919050565b60006040820190506112a36000830185610be9565b6112b06020830184610be9565b9392505050565b60006112c282610bdf565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036112f4576112f3610e6e565b5b60018201905091905056fea2646970667358221220d8080ab5a4c87b916e53db0d7e079741051d893c1b71c903931d408465ab7f8e64736f6c634300081c003300000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000003
Deployed Bytecode
0x60806040526004361061007f5760003560e01c806393e84cd91161004e57806393e84cd914610149578063c323400c14610153578063d7c81b551461017e578063f71d96cb146101a957610086565b80631a39d8ef1461008b57806332d0bbe3146100b657806370d20d3e146100f35780638da5cb5b1461011e57610086565b3661008657005b600080fd5b34801561009757600080fd5b506100a06101e7565b6040516100ad9190610bf8565b60405180910390f35b3480156100c257600080fd5b506100dd60048036038101906100d89190610c76565b6101ed565b6040516100ea9190610cbe565b60405180910390f35b3480156100ff57600080fd5b5061010861020d565b6040516101159190610bf8565b60405180910390f35b34801561012a57600080fd5b50610133610231565b6040516101409190610ce8565b60405180910390f35b610151610255565b005b34801561015f57600080fd5b506101686104bb565b6040516101759190610bf8565b60405180910390f35b34801561018a57600080fd5b506101936104df565b6040516101a09190610bf8565b60405180910390f35b3480156101b557600080fd5b506101d060048036038101906101cb9190610d2f565b6104e5565b6040516101de929190610d5c565b60405180910390f35b60035481565b60026020528060005260406000206000915054906101000a900460ff1681565b7f000000000000000000000000000000000000000000000000000000000000000381565b7f000000000000000000000000d0a7bf4626ccadfe37e38e5d52944c223b22b77981565b61025d610539565b600260003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16156102ea576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016102e190610de2565b60405180910390fd5b6000341161032d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161032490610e4e565b60405180910390fd5b600160405180604001604052803373ffffffffffffffffffffffffffffffffffffffff16815260200134815250908060018154018082558091505060019003906000526020600020906002020160009091909190915060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506020820151816001015550506001600260003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff02191690831515021790555034600360008282546104409190610e9d565b925050819055503373ffffffffffffffffffffffffffffffffffffffff167f3330a6773675f31f62070870f40379f8c6d42e3761410011a4dfc42b18043d2f3460405161048d9190610bf8565b60405180910390a26104a3600180549050610588565b156104b1576104b0610702565b5b6104b9610b3c565b565b7f000000000000000000000000000000000000000000000000000000000000000281565b60045481565b600181815481106104f557600080fd5b90600052602060002090600202016000915090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060010154905082565b60026000540361057e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161057590610f1d565b60405180910390fd5b6002600081905550565b60008060017f00000000000000000000000000000000000000000000000000000000000000027f00000000000000000000000000000000000000000000000000000000000000036105d99190610f3d565b6105e39190610e9d565b4442856040516020016105f893929190610f92565b6040516020818303038152906040528051906020012060001c61061b9190610ffe565b7f00000000000000000000000000000000000000000000000000000000000000026106469190610e9d565b90508083101561065a5760009150506106fd565b600081841161066a576001610677565b81846106769190610f3d565b5b9050600082856106879190610e9d565b90506000600183836106999190610f3d565b6106a39190610e9d565b6001436106b09190610f3d565b40336040516020016106c39291906110a2565b6040516020818303038152906040528051906020012060001c6106e69190610ffe565b836106f19190610e9d565b90508581149450505050505b919050565b600060018054905060035461071791906110ce565b90506000600360028361072a91906110ff565b61073491906110ce565b90506000600160008154811061074d5761074c611141565b5b906000526020600020906002020160000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905060006107b3600160008154811061079b5761079a611141565b5b90600052602060002090600202016001015484610b46565b90506000600190505b60018054905081101561085c5760006107fa600183815481106107e2576107e1611141565b5b90600052602060002090600202016001015486610b46565b905082811015610850576001828154811061081857610817611141565b5b906000526020600020906002020160000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1693508092505b508060010190506107bc565b506000606460035461086e91906110ce565b90506000816003546108809190610f3d565b905060008473ffffffffffffffffffffffffffffffffffffffff16826040516108a8906111a1565b60006040518083038185875af1925050503d80600081146108e5576040519150601f19603f3d011682016040523d82523d6000602084013e6108ea565b606091505b505090508061092e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161092590611202565b60405180910390fd5b60007f000000000000000000000000d0a7bf4626ccadfe37e38e5d52944c223b22b77973ffffffffffffffffffffffffffffffffffffffff1684604051610974906111a1565b60006040518083038185875af1925050503d80600081146109b1576040519150601f19603f3d011682016040523d82523d6000602084013e6109b6565b606091505b50509050806109fa576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016109f19061126e565b60405180910390fd5b8573ffffffffffffffffffffffffffffffffffffffff166004547f64e67454795640f66cef8019a707b9381952f2f1024a355d5470bafc82af1800858a604051610a4592919061128e565b60405180910390a360005b600180549050811015610b055760006002600060018481548110610a7757610a76611141565b5b906000526020600020906002020160000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff021916908315150217905550806001019050610a50565b5060016000610b149190610b75565b6000600381905550600460008154610b2b906112b7565b919050819055505050505050505050565b6001600081905550565b6000818311610b60578282610b5b9190610f3d565b610b6d565b8183610b6c9190610f3d565b5b905092915050565b5080546000825560020290600052602060002090810190610b969190610b99565b50565b5b80821115610bdb57600080820160006101000a81549073ffffffffffffffffffffffffffffffffffffffff0219169055600182016000905550600201610b9a565b5090565b6000819050919050565b610bf281610bdf565b82525050565b6000602082019050610c0d6000830184610be9565b92915050565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000610c4382610c18565b9050919050565b610c5381610c38565b8114610c5e57600080fd5b50565b600081359050610c7081610c4a565b92915050565b600060208284031215610c8c57610c8b610c13565b5b6000610c9a84828501610c61565b91505092915050565b60008115159050919050565b610cb881610ca3565b82525050565b6000602082019050610cd36000830184610caf565b92915050565b610ce281610c38565b82525050565b6000602082019050610cfd6000830184610cd9565b92915050565b610d0c81610bdf565b8114610d1757600080fd5b50565b600081359050610d2981610d03565b92915050565b600060208284031215610d4557610d44610c13565b5b6000610d5384828501610d1a565b91505092915050565b6000604082019050610d716000830185610cd9565b610d7e6020830184610be9565b9392505050565b600082825260208201905092915050565b7f596f7520616c726561647920706c617965640000000000000000000000000000600082015250565b6000610dcc601283610d85565b9150610dd782610d96565b602082019050919050565b60006020820190508181036000830152610dfb81610dbf565b9050919050565b7f4d7573742073656e6420455448203e2030000000000000000000000000000000600082015250565b6000610e38601183610d85565b9150610e4382610e02565b602082019050919050565b60006020820190508181036000830152610e6781610e2b565b9050919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000610ea882610bdf565b9150610eb383610bdf565b9250828201905080821115610ecb57610eca610e6e565b5b92915050565b7f5265656e7472616e637947756172643a207265656e7472616e742063616c6c00600082015250565b6000610f07601f83610d85565b9150610f1282610ed1565b602082019050919050565b60006020820190508181036000830152610f3681610efa565b9050919050565b6000610f4882610bdf565b9150610f5383610bdf565b9250828203905081811115610f6b57610f6a610e6e565b5b92915050565b6000819050919050565b610f8c610f8782610bdf565b610f71565b82525050565b6000610f9e8286610f7b565b602082019150610fae8285610f7b565b602082019150610fbe8284610f7b565b602082019150819050949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600061100982610bdf565b915061101483610bdf565b92508261102457611023610fcf565b5b828206905092915050565b6000819050919050565b6000819050919050565b61105461104f8261102f565b611039565b82525050565b60008160601b9050919050565b60006110728261105a565b9050919050565b600061108482611067565b9050919050565b61109c61109782610c38565b611079565b82525050565b60006110ae8285611043565b6020820191506110be828461108b565b6014820191508190509392505050565b60006110d982610bdf565b91506110e483610bdf565b9250826110f4576110f3610fcf565b5b828204905092915050565b600061110a82610bdf565b915061111583610bdf565b925082820261112381610bdf565b9150828204841483151761113a57611139610e6e565b5b5092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600081905092915050565b50565b600061118b600083611170565b91506111968261117b565b600082019050919050565b60006111ac8261117e565b9150819050919050565b7f5072697a65207472616e73666572206661696c65640000000000000000000000600082015250565b60006111ec601583610d85565b91506111f7826111b6565b602082019050919050565b6000602082019050818103600083015261121b816111df565b9050919050565b7f466565207472616e73666572206661696c656400000000000000000000000000600082015250565b6000611258601383610d85565b915061126382611222565b602082019050919050565b600060208201905081810360008301526112878161124b565b9050919050565b60006040820190506112a36000830185610be9565b6112b06020830184610be9565b9392505050565b60006112c282610bdf565b91507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036112f4576112f3610e6e565b5b60018201905091905056fea2646970667358221220d8080ab5a4c87b916e53db0d7e079741051d893c1b71c903931d408465ab7f8e64736f6c634300081c0033
Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000003
-----Decoded View---------------
Arg [0] : _minX (uint256): 2
Arg [1] : _maxX (uint256): 3
-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000002
Arg [1] : 0000000000000000000000000000000000000000000000000000000000000003
Loading...
Loading
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 34 Chains
| Chain | Token | Portfolio % | Price | Amount | Value |
|---|---|---|---|---|---|
| BASE | 100.00% | $3,096.56 | 0.00001 | $0.030975 |
Loading...
Loading
Loading...
Loading
Loading...
Loading
[ Download: CSV Export ]
A contract address hosts a smart contract, which is a set of code stored on the blockchain that runs when predetermined conditions are met. Learn more about addresses in our Knowledge Base.