Overview
ETH Balance
0 ETH
Eth Value
$0.00More Info
Private Name Tags
ContractCreator
View more zero value Internal Transactions in Advanced View mode
Advanced mode:
Loading...
Loading
Contract Name:
TimeHelpers
Compiler Version
v0.8.11+commit.d7f03943
Optimization Enabled:
Yes with 200 runs
Other Settings:
default evmVersion
Contract Source Code (Solidity Standard Json-Input format)
// SPDX-License-Identifier: AGPL-3.0-only /* TimeHelpers.sol - SKALE Manager Copyright (C) 2019-Present SKALE Labs @author Dmytro Stebaiev SKALE Manager is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. SKALE Manager is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with SKALE Manager. If not, see <https://www.gnu.org/licenses/>. */ pragma solidity 0.8.11; import "@skalenetwork/skale-manager-interfaces/delegation/ITimeHelpers.sol"; import "../thirdparty/BokkyPooBahsDateTimeLibrary.sol"; /** * @title TimeHelpers * @dev The contract performs time operations. * * These functions are used to calculate monthly and Proof of Use epochs. */ contract TimeHelpers is ITimeHelpers { uint constant private _ZERO_YEAR = 2020; function calculateProofOfUseLockEndTime(uint month, uint lockUpPeriodDays) external view override returns (uint timestamp) { timestamp = BokkyPooBahsDateTimeLibrary.addDays(monthToTimestamp(month), lockUpPeriodDays); } function getCurrentMonth() external view virtual override returns (uint) { return timestampToMonth(block.timestamp); } function timestampToYear(uint timestamp) external view virtual override returns (uint) { uint year; (year, , ) = BokkyPooBahsDateTimeLibrary.timestampToDate(timestamp); require(year >= _ZERO_YEAR, "Timestamp is too far in the past"); return year - _ZERO_YEAR; } function addDays(uint fromTimestamp, uint n) external pure override returns (uint) { return BokkyPooBahsDateTimeLibrary.addDays(fromTimestamp, n); } function addMonths(uint fromTimestamp, uint n) external pure override returns (uint) { return BokkyPooBahsDateTimeLibrary.addMonths(fromTimestamp, n); } function addYears(uint fromTimestamp, uint n) external pure override returns (uint) { return BokkyPooBahsDateTimeLibrary.addYears(fromTimestamp, n); } function timestampToMonth(uint timestamp) public view virtual override returns (uint) { uint year; uint month; (year, month, ) = BokkyPooBahsDateTimeLibrary.timestampToDate(timestamp); require(year >= _ZERO_YEAR, "Timestamp is too far in the past"); month = month - 1 + (year - _ZERO_YEAR) * 12; require(month > 0, "Timestamp is too far in the past"); return month; } function monthToTimestamp(uint month) public view virtual override returns (uint timestamp) { uint year = _ZERO_YEAR; uint _month = month; year = year + _month / 12; _month = _month % 12; _month = _month + 1; return BokkyPooBahsDateTimeLibrary.timestampFromDate(year, _month, 1); } }
// SPDX-License-Identifier: AGPL-3.0-only /* ITimeHelpers.sol - SKALE Manager Copyright (C) 2018-Present SKALE Labs @author Artem Payvin SKALE Manager is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. SKALE Manager is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with SKALE Manager. If not, see <https://www.gnu.org/licenses/>. */ pragma solidity >=0.6.10 <0.9.0; interface ITimeHelpers { function calculateProofOfUseLockEndTime(uint month, uint lockUpPeriodDays) external view returns (uint timestamp); function getCurrentMonth() external view returns (uint); function timestampToYear(uint timestamp) external view returns (uint); function timestampToMonth(uint timestamp) external view returns (uint); function monthToTimestamp(uint month) external view returns (uint timestamp); function addDays(uint fromTimestamp, uint n) external pure returns (uint); function addMonths(uint fromTimestamp, uint n) external pure returns (uint); function addYears(uint fromTimestamp, uint n) external pure returns (uint); }
// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; // ---------------------------------------------------------------------------- // BokkyPooBah's DateTime Library v1.01 // // A gas-efficient Solidity date and time library // // https://github.com/bokkypoobah/BokkyPooBahsDateTimeLibrary // // Tested date range 1970/01/01 to 2345/12/31 // // Conventions: // Unit | Range | Notes // :-------- |:-------------:|:----- // timestamp | >= 0 | Unix timestamp, number of seconds since 1970/01/01 00:00:00 UTC // year | 1970 ... 2345 | // month | 1 ... 12 | // day | 1 ... 31 | // hour | 0 ... 23 | // minute | 0 ... 59 | // second | 0 ... 59 | // dayOfWeek | 1 ... 7 | 1 = Monday, ..., 7 = Sunday // // // Enjoy. (c) BokkyPooBah / Bok Consulting Pty Ltd 2018-2019. The MIT Licence. // ---------------------------------------------------------------------------- library BokkyPooBahsDateTimeLibrary { uint constant SECONDS_PER_DAY = 24 * 60 * 60; uint constant SECONDS_PER_HOUR = 60 * 60; uint constant SECONDS_PER_MINUTE = 60; int constant OFFSET19700101 = 2440588; uint constant DOW_MON = 1; uint constant DOW_TUE = 2; uint constant DOW_WED = 3; uint constant DOW_THU = 4; uint constant DOW_FRI = 5; uint constant DOW_SAT = 6; uint constant DOW_SUN = 7; // ------------------------------------------------------------------------ // Calculate the number of days from 1970/01/01 to year/month/day using // the date conversion algorithm from // http://aa.usno.navy.mil/faq/docs/JD_Formula.php // and subtracting the offset 2440588 so that 1970/01/01 is day 0 // // days = day // - 32075 // + 1461 * (year + 4800 + (month - 14) / 12) / 4 // + 367 * (month - 2 - (month - 14) / 12 * 12) / 12 // - 3 * ((year + 4900 + (month - 14) / 12) / 100) / 4 // - offset // ------------------------------------------------------------------------ function _daysFromDate(uint year, uint month, uint day) internal pure returns (uint _days) { require(year >= 1970); int _year = int(year); int _month = int(month); int _day = int(day); int __days = _day - 32075 + 1461 * (_year + 4800 + (_month - 14) / 12) / 4 + 367 * (_month - 2 - (_month - 14) / 12 * 12) / 12 - 3 * ((_year + 4900 + (_month - 14) / 12) / 100) / 4 - OFFSET19700101; _days = uint(__days); } // ------------------------------------------------------------------------ // Calculate year/month/day from the number of days since 1970/01/01 using // the date conversion algorithm from // http://aa.usno.navy.mil/faq/docs/JD_Formula.php // and adding the offset 2440588 so that 1970/01/01 is day 0 // // int L = days + 68569 + offset // int N = 4 * L / 146097 // L = L - (146097 * N + 3) / 4 // year = 4000 * (L + 1) / 1461001 // L = L - 1461 * year / 4 + 31 // month = 80 * L / 2447 // dd = L - 2447 * month / 80 // L = month / 11 // month = month + 2 - 12 * L // year = 100 * (N - 49) + year + L // ------------------------------------------------------------------------ function _daysToDate(uint _days) internal pure returns (uint year, uint month, uint day) { int __days = int(_days); int L = __days + 68569 + OFFSET19700101; int N = 4 * L / 146097; L = L - (146097 * N + 3) / 4; int _year = 4000 * (L + 1) / 1461001; L = L - 1461 * _year / 4 + 31; int _month = 80 * L / 2447; int _day = L - 2447 * _month / 80; L = _month / 11; _month = _month + 2 - 12 * L; _year = 100 * (N - 49) + _year + L; year = uint(_year); month = uint(_month); day = uint(_day); } function timestampFromDate(uint year, uint month, uint day) internal pure returns (uint timestamp) { timestamp = _daysFromDate(year, month, day) * SECONDS_PER_DAY; } function timestampFromDateTime(uint year, uint month, uint day, uint hour, uint minute, uint second) internal pure returns (uint timestamp) { timestamp = _daysFromDate(year, month, day) * SECONDS_PER_DAY + hour * SECONDS_PER_HOUR + minute * SECONDS_PER_MINUTE + second; } function timestampToDate(uint timestamp) internal pure returns (uint year, uint month, uint day) { (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); } function timestampToDateTime(uint timestamp) internal pure returns (uint year, uint month, uint day, uint hour, uint minute, uint second) { (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); uint secs = timestamp % SECONDS_PER_DAY; hour = secs / SECONDS_PER_HOUR; secs = secs % SECONDS_PER_HOUR; minute = secs / SECONDS_PER_MINUTE; second = secs % SECONDS_PER_MINUTE; } function isValidDate(uint year, uint month, uint day) internal pure returns (bool valid) { if (year >= 1970 && month > 0 && month <= 12) { uint daysInMonth = _getDaysInMonth(year, month); if (day > 0 && day <= daysInMonth) { valid = true; } } } function isValidDateTime(uint year, uint month, uint day, uint hour, uint minute, uint second) internal pure returns (bool valid) { if (isValidDate(year, month, day)) { if (hour < 24 && minute < 60 && second < 60) { valid = true; } } } function isLeapYear(uint timestamp) internal pure returns (bool leapYear) { uint year; uint month; uint day; (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); leapYear = _isLeapYear(year); } function _isLeapYear(uint year) internal pure returns (bool leapYear) { leapYear = ((year % 4 == 0) && (year % 100 != 0)) || (year % 400 == 0); } function isWeekDay(uint timestamp) internal pure returns (bool weekDay) { weekDay = getDayOfWeek(timestamp) <= DOW_FRI; } function isWeekEnd(uint timestamp) internal pure returns (bool weekEnd) { weekEnd = getDayOfWeek(timestamp) >= DOW_SAT; } function getDaysInMonth(uint timestamp) internal pure returns (uint daysInMonth) { uint year; uint month; uint day; (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); daysInMonth = _getDaysInMonth(year, month); } function _getDaysInMonth(uint year, uint month) internal pure returns (uint daysInMonth) { if (month == 1 || month == 3 || month == 5 || month == 7 || month == 8 || month == 10 || month == 12) { daysInMonth = 31; } else if (month != 2) { daysInMonth = 30; } else { daysInMonth = _isLeapYear(year) ? 29 : 28; } } // 1 = Monday, 7 = Sunday function getDayOfWeek(uint timestamp) internal pure returns (uint dayOfWeek) { uint _days = timestamp / SECONDS_PER_DAY; dayOfWeek = (_days + 3) % 7 + 1; } function getYear(uint timestamp) internal pure returns (uint year) { uint month; uint day; (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); } function getMonth(uint timestamp) internal pure returns (uint month) { uint year; uint day; (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); } function getDay(uint timestamp) internal pure returns (uint day) { uint year; uint month; (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); } function getHour(uint timestamp) internal pure returns (uint hour) { uint secs = timestamp % SECONDS_PER_DAY; hour = secs / SECONDS_PER_HOUR; } function getMinute(uint timestamp) internal pure returns (uint minute) { uint secs = timestamp % SECONDS_PER_HOUR; minute = secs / SECONDS_PER_MINUTE; } function getSecond(uint timestamp) internal pure returns (uint second) { second = timestamp % SECONDS_PER_MINUTE; } function addYears(uint timestamp, uint _years) internal pure returns (uint newTimestamp) { uint year; uint month; uint day; (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); year += _years; uint daysInMonth = _getDaysInMonth(year, month); if (day > daysInMonth) { day = daysInMonth; } newTimestamp = _daysFromDate(year, month, day) * SECONDS_PER_DAY + timestamp % SECONDS_PER_DAY; require(newTimestamp >= timestamp); } function addMonths(uint timestamp, uint _months) internal pure returns (uint newTimestamp) { uint year; uint month; uint day; (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); month += _months; year += (month - 1) / 12; month = (month - 1) % 12 + 1; uint daysInMonth = _getDaysInMonth(year, month); if (day > daysInMonth) { day = daysInMonth; } newTimestamp = _daysFromDate(year, month, day) * SECONDS_PER_DAY + timestamp % SECONDS_PER_DAY; require(newTimestamp >= timestamp); } function addDays(uint timestamp, uint _days) internal pure returns (uint newTimestamp) { newTimestamp = timestamp + _days * SECONDS_PER_DAY; require(newTimestamp >= timestamp); } function addHours(uint timestamp, uint _hours) internal pure returns (uint newTimestamp) { newTimestamp = timestamp + _hours * SECONDS_PER_HOUR; require(newTimestamp >= timestamp); } function addMinutes(uint timestamp, uint _minutes) internal pure returns (uint newTimestamp) { newTimestamp = timestamp + _minutes * SECONDS_PER_MINUTE; require(newTimestamp >= timestamp); } function addSeconds(uint timestamp, uint _seconds) internal pure returns (uint newTimestamp) { newTimestamp = timestamp + _seconds; require(newTimestamp >= timestamp); } function subYears(uint timestamp, uint _years) internal pure returns (uint newTimestamp) { uint year; uint month; uint day; (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); year -= _years; uint daysInMonth = _getDaysInMonth(year, month); if (day > daysInMonth) { day = daysInMonth; } newTimestamp = _daysFromDate(year, month, day) * SECONDS_PER_DAY + timestamp % SECONDS_PER_DAY; require(newTimestamp <= timestamp); } function subMonths(uint timestamp, uint _months) internal pure returns (uint newTimestamp) { uint year; uint month; uint day; (year, month, day) = _daysToDate(timestamp / SECONDS_PER_DAY); uint yearMonth = year * 12 + (month - 1) - _months; year = yearMonth / 12; month = yearMonth % 12 + 1; uint daysInMonth = _getDaysInMonth(year, month); if (day > daysInMonth) { day = daysInMonth; } newTimestamp = _daysFromDate(year, month, day) * SECONDS_PER_DAY + timestamp % SECONDS_PER_DAY; require(newTimestamp <= timestamp); } function subDays(uint timestamp, uint _days) internal pure returns (uint newTimestamp) { newTimestamp = timestamp - _days * SECONDS_PER_DAY; require(newTimestamp <= timestamp); } function subHours(uint timestamp, uint _hours) internal pure returns (uint newTimestamp) { newTimestamp = timestamp - _hours * SECONDS_PER_HOUR; require(newTimestamp <= timestamp); } function subMinutes(uint timestamp, uint _minutes) internal pure returns (uint newTimestamp) { newTimestamp = timestamp - _minutes * SECONDS_PER_MINUTE; require(newTimestamp <= timestamp); } function subSeconds(uint timestamp, uint _seconds) internal pure returns (uint newTimestamp) { newTimestamp = timestamp - _seconds; require(newTimestamp <= timestamp); } function diffYears(uint fromTimestamp, uint toTimestamp) internal pure returns (uint _years) { require(fromTimestamp <= toTimestamp); uint fromYear; uint fromMonth; uint fromDay; uint toYear; uint toMonth; uint toDay; (fromYear, fromMonth, fromDay) = _daysToDate(fromTimestamp / SECONDS_PER_DAY); (toYear, toMonth, toDay) = _daysToDate(toTimestamp / SECONDS_PER_DAY); _years = toYear - fromYear; } function diffMonths(uint fromTimestamp, uint toTimestamp) internal pure returns (uint _months) { require(fromTimestamp <= toTimestamp); uint fromYear; uint fromMonth; uint fromDay; uint toYear; uint toMonth; uint toDay; (fromYear, fromMonth, fromDay) = _daysToDate(fromTimestamp / SECONDS_PER_DAY); (toYear, toMonth, toDay) = _daysToDate(toTimestamp / SECONDS_PER_DAY); _months = toYear * 12 + toMonth - fromYear * 12 - fromMonth; } function diffDays(uint fromTimestamp, uint toTimestamp) internal pure returns (uint _days) { require(fromTimestamp <= toTimestamp); _days = (toTimestamp - fromTimestamp) / SECONDS_PER_DAY; } function diffHours(uint fromTimestamp, uint toTimestamp) internal pure returns (uint _hours) { require(fromTimestamp <= toTimestamp); _hours = (toTimestamp - fromTimestamp) / SECONDS_PER_HOUR; } function diffMinutes(uint fromTimestamp, uint toTimestamp) internal pure returns (uint _minutes) { require(fromTimestamp <= toTimestamp); _minutes = (toTimestamp - fromTimestamp) / SECONDS_PER_MINUTE; } function diffSeconds(uint fromTimestamp, uint toTimestamp) internal pure returns (uint _seconds) { require(fromTimestamp <= toTimestamp); _seconds = toTimestamp - fromTimestamp; } }
{ "optimizer": { "enabled": true, "runs": 200 }, "outputSelection": { "*": { "*": [ "evm.bytecode", "evm.deployedBytecode", "devdoc", "userdoc", "metadata", "abi" ] } }, "libraries": {} }
Contract Security Audit
- No Contract Security Audit Submitted- Submit Audit Here
[{"inputs":[{"internalType":"uint256","name":"fromTimestamp","type":"uint256"},{"internalType":"uint256","name":"n","type":"uint256"}],"name":"addDays","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"fromTimestamp","type":"uint256"},{"internalType":"uint256","name":"n","type":"uint256"}],"name":"addMonths","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"fromTimestamp","type":"uint256"},{"internalType":"uint256","name":"n","type":"uint256"}],"name":"addYears","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"month","type":"uint256"},{"internalType":"uint256","name":"lockUpPeriodDays","type":"uint256"}],"name":"calculateProofOfUseLockEndTime","outputs":[{"internalType":"uint256","name":"timestamp","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCurrentMonth","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"month","type":"uint256"}],"name":"monthToTimestamp","outputs":[{"internalType":"uint256","name":"timestamp","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"timestampToMonth","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"timestamp","type":"uint256"}],"name":"timestampToYear","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"}]
Contract Creation Code
608060405234801561001057600080fd5b506109f5806100206000396000f3fe608060405234801561001057600080fd5b50600436106100885760003560e01c8063568b55b21161005b578063568b55b2146100eb5780637217523c146100fe578063bf64d84914610111578063ddd1b67e1461012457600080fd5b80632713b2c61461008d5780634355644d146100b2578063442b8c79146100c5578063489a636f146100d8575b600080fd5b6100a061009b36600461077a565b61012c565b60405190815260200160405180910390f35b6100a06100c036600461077a565b610147565b6100a06100d336600461077a565b610159565b6100a06100e636600461079c565b610165565b6100a06100f936600461079c565b6101ad565b6100a061010c36600461077a565b6101f8565b6100a061011f36600461079c565b610204565b6100a0610288565b600061014061013a846101ad565b83610298565b9392505050565b600061014083836102c0565b92915050565b60006101408383610397565b600080610171836103cb565b50909150506107e48110156101a15760405162461bcd60e51b8152600401610198906107b5565b60405180910390fd5b6101406107e482610800565b60006107e4826101be600c8261082d565b6101c89083610841565b91506101d5600c82610859565b90506101e2816001610841565b90506101f0828260016103ec565b949350505050565b60006101408383610298565b6000806000610212846103cb565b5090925090506107e482101561023a5760405162461bcd60e51b8152600401610198906107b5565b6102466107e483610800565b61025190600c61086d565b61025c600183610800565b6102669190610841565b9050600081116101405760405162461bcd60e51b8152600401610198906107b5565b600061029342610204565b905090565b60006102a7620151808361086d565b6102b19084610841565b90508281101561015357600080fd5b60008080806102da6102d5620151808861082d565b610407565b919450925090506102eb8583610841565b9150600c6102fa600184610800565b610304919061082d565b61030e9084610841565b9250600c61031d600184610800565b6103279190610859565b610332906001610841565b91506000610340848461057b565b90508082111561034e578091505b61035b6201518088610859565b6201518061036a868686610601565b610374919061086d565b61037e9190610841565b94508685101561038d57600080fd5b5050505092915050565b60008080806103ac6102d5620151808861082d565b919450925090506103bd8584610841565b92506000610340848461057b565b600080806103df6102d5620151808661082d565b9196909550909350915050565b6000620151806103fd858585610601565b6101f0919061086d565b60008080838162253d8c61041e8362010bd961088c565b610428919061088c565b9050600062023ab161043b8360046108cd565b6104459190610952565b905060046104568262023ab16108cd565b61046190600361088c565b61046b9190610952565b6104759083610980565b9150600062164b0961048884600161088c565b61049490610fa06108cd565b61049e9190610952565b905060046104ae826105b56108cd565b6104b89190610952565b6104c29084610980565b6104cd90601f61088c565b9250600061098f6104df8560506108cd565b6104e99190610952565b9050600060506104fb8361098f6108cd565b6105059190610952565b61050f9086610980565b905061051c600b83610952565b945061052985600c6108cd565b61053483600261088c565b61053e9190610980565b9150848361054d603187610980565b6105589060646108cd565b610562919061088c565b61056c919061088c565b9a919950975095505050505050565b6000816001148061058c5750816003145b806105975750816005145b806105a25750816007145b806105ad5750816008145b806105b8575081600a145b806105c3575081600c145b156105d05750601f610153565b816002146105e05750601e610153565b6105e98361073e565b6105f457601c6105f7565b601d5b60ff169392505050565b60006107b284101561061257600080fd5b838383600062253d8c60046064600c61062c600e88610980565b6106369190610952565b6106428861132461088c565b61064c919061088c565b6106569190610952565b6106619060036108cd565b61066b9190610952565b600c80610679600e88610980565b6106839190610952565b61068e90600c6108cd565b610699600288610980565b6106a39190610980565b6106af9061016f6108cd565b6106b99190610952565b6004600c6106c8600e89610980565b6106d29190610952565b6106de896112c061088c565b6106e8919061088c565b6106f4906105b56108cd565b6106fe9190610952565b61070a617d4b87610980565b610714919061088c565b61071e919061088c565b6107289190610980565b6107329190610980565b98975050505050505050565b600061074b600483610859565b158015610761575061075e606483610859565b15155b80610153575061077361019083610859565b1592915050565b6000806040838503121561078d57600080fd5b50508035926020909101359150565b6000602082840312156107ae57600080fd5b5035919050565b6020808252818101527f54696d657374616d7020697320746f6f2066617220696e207468652070617374604082015260600190565b634e487b7160e01b600052601160045260246000fd5b600082821015610812576108126107ea565b500390565b634e487b7160e01b600052601260045260246000fd5b60008261083c5761083c610817565b500490565b60008219821115610854576108546107ea565b500190565b60008261086857610868610817565b500690565b6000816000190483118215151615610887576108876107ea565b500290565b600080821280156001600160ff1b03849003851316156108ae576108ae6107ea565b600160ff1b83900384128116156108c7576108c76107ea565b50500190565b60006001600160ff1b03818413828413808216868404861116156108f3576108f36107ea565b600160ff1b6000871282811687830589121615610912576109126107ea565b6000871292508782058712848416161561092e5761092e6107ea565b87850587128184161615610944576109446107ea565b505050929093029392505050565b60008261096157610961610817565b600160ff1b82146000198414161561097b5761097b6107ea565b500590565b60008083128015600160ff1b85018412161561099e5761099e6107ea565b6001600160ff1b03840183138116156109b9576109b96107ea565b5050039056fea2646970667358221220892229441b18b0f982679f6252af74f031381ed97546dfd61b1e3863546344dd64736f6c634300080b0033
Deployed Bytecode
0x608060405234801561001057600080fd5b50600436106100885760003560e01c8063568b55b21161005b578063568b55b2146100eb5780637217523c146100fe578063bf64d84914610111578063ddd1b67e1461012457600080fd5b80632713b2c61461008d5780634355644d146100b2578063442b8c79146100c5578063489a636f146100d8575b600080fd5b6100a061009b36600461077a565b61012c565b60405190815260200160405180910390f35b6100a06100c036600461077a565b610147565b6100a06100d336600461077a565b610159565b6100a06100e636600461079c565b610165565b6100a06100f936600461079c565b6101ad565b6100a061010c36600461077a565b6101f8565b6100a061011f36600461079c565b610204565b6100a0610288565b600061014061013a846101ad565b83610298565b9392505050565b600061014083836102c0565b92915050565b60006101408383610397565b600080610171836103cb565b50909150506107e48110156101a15760405162461bcd60e51b8152600401610198906107b5565b60405180910390fd5b6101406107e482610800565b60006107e4826101be600c8261082d565b6101c89083610841565b91506101d5600c82610859565b90506101e2816001610841565b90506101f0828260016103ec565b949350505050565b60006101408383610298565b6000806000610212846103cb565b5090925090506107e482101561023a5760405162461bcd60e51b8152600401610198906107b5565b6102466107e483610800565b61025190600c61086d565b61025c600183610800565b6102669190610841565b9050600081116101405760405162461bcd60e51b8152600401610198906107b5565b600061029342610204565b905090565b60006102a7620151808361086d565b6102b19084610841565b90508281101561015357600080fd5b60008080806102da6102d5620151808861082d565b610407565b919450925090506102eb8583610841565b9150600c6102fa600184610800565b610304919061082d565b61030e9084610841565b9250600c61031d600184610800565b6103279190610859565b610332906001610841565b91506000610340848461057b565b90508082111561034e578091505b61035b6201518088610859565b6201518061036a868686610601565b610374919061086d565b61037e9190610841565b94508685101561038d57600080fd5b5050505092915050565b60008080806103ac6102d5620151808861082d565b919450925090506103bd8584610841565b92506000610340848461057b565b600080806103df6102d5620151808661082d565b9196909550909350915050565b6000620151806103fd858585610601565b6101f0919061086d565b60008080838162253d8c61041e8362010bd961088c565b610428919061088c565b9050600062023ab161043b8360046108cd565b6104459190610952565b905060046104568262023ab16108cd565b61046190600361088c565b61046b9190610952565b6104759083610980565b9150600062164b0961048884600161088c565b61049490610fa06108cd565b61049e9190610952565b905060046104ae826105b56108cd565b6104b89190610952565b6104c29084610980565b6104cd90601f61088c565b9250600061098f6104df8560506108cd565b6104e99190610952565b9050600060506104fb8361098f6108cd565b6105059190610952565b61050f9086610980565b905061051c600b83610952565b945061052985600c6108cd565b61053483600261088c565b61053e9190610980565b9150848361054d603187610980565b6105589060646108cd565b610562919061088c565b61056c919061088c565b9a919950975095505050505050565b6000816001148061058c5750816003145b806105975750816005145b806105a25750816007145b806105ad5750816008145b806105b8575081600a145b806105c3575081600c145b156105d05750601f610153565b816002146105e05750601e610153565b6105e98361073e565b6105f457601c6105f7565b601d5b60ff169392505050565b60006107b284101561061257600080fd5b838383600062253d8c60046064600c61062c600e88610980565b6106369190610952565b6106428861132461088c565b61064c919061088c565b6106569190610952565b6106619060036108cd565b61066b9190610952565b600c80610679600e88610980565b6106839190610952565b61068e90600c6108cd565b610699600288610980565b6106a39190610980565b6106af9061016f6108cd565b6106b99190610952565b6004600c6106c8600e89610980565b6106d29190610952565b6106de896112c061088c565b6106e8919061088c565b6106f4906105b56108cd565b6106fe9190610952565b61070a617d4b87610980565b610714919061088c565b61071e919061088c565b6107289190610980565b6107329190610980565b98975050505050505050565b600061074b600483610859565b158015610761575061075e606483610859565b15155b80610153575061077361019083610859565b1592915050565b6000806040838503121561078d57600080fd5b50508035926020909101359150565b6000602082840312156107ae57600080fd5b5035919050565b6020808252818101527f54696d657374616d7020697320746f6f2066617220696e207468652070617374604082015260600190565b634e487b7160e01b600052601160045260246000fd5b600082821015610812576108126107ea565b500390565b634e487b7160e01b600052601260045260246000fd5b60008261083c5761083c610817565b500490565b60008219821115610854576108546107ea565b500190565b60008261086857610868610817565b500690565b6000816000190483118215151615610887576108876107ea565b500290565b600080821280156001600160ff1b03849003851316156108ae576108ae6107ea565b600160ff1b83900384128116156108c7576108c76107ea565b50500190565b60006001600160ff1b03818413828413808216868404861116156108f3576108f36107ea565b600160ff1b6000871282811687830589121615610912576109126107ea565b6000871292508782058712848416161561092e5761092e6107ea565b87850587128184161615610944576109446107ea565b505050929093029392505050565b60008261096157610961610817565b600160ff1b82146000198414161561097b5761097b6107ea565b500590565b60008083128015600160ff1b85018412161561099e5761099e6107ea565b6001600160ff1b03840183138116156109b9576109b96107ea565b5050039056fea2646970667358221220892229441b18b0f982679f6252af74f031381ed97546dfd61b1e3863546344dd64736f6c634300080b0033
Loading...
Loading
Loading...
Loading
Multichain Portfolio | 30 Chains
Chain | Token | Portfolio % | Price | Amount | Value |
---|
Loading...
Loading
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.