Contract 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c

 
Txn Hash Method
Block
From
To
Value
0xdb266c3839d717878c214c79b9fe87373fcaa6e4c4e6a41d571233b66b9533a80x60806040323306462022-10-28 17:11:38485 days 7 hrs ago0x5b0390bccca1f040d8993eb6e4ce8ded93721765 IN  Create: TarotSolidlyPriceOracleV20 ETH0.0011349239730.001
[ Download CSV Export 
Latest 25 internal transaction
Parent Txn Hash Block From To Value
0x0f20c89afef551cfe889b367c1bc9aeb0d35831a43ec09b38c66195a8386cc8a1075580832023-07-30 11:02:23210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x0f20c89afef551cfe889b367c1bc9aeb0d35831a43ec09b38c66195a8386cc8a1075580832023-07-30 11:02:23210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x0f20c89afef551cfe889b367c1bc9aeb0d35831a43ec09b38c66195a8386cc8a1075580832023-07-30 11:02:23210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x0f20c89afef551cfe889b367c1bc9aeb0d35831a43ec09b38c66195a8386cc8a1075580832023-07-30 11:02:23210 days 13 hrs ago 0x554197e3593c2262a8ad0bfb22835f28f4bc384d 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c0 ETH
0xdd190c39305d44376d583cf99a182f70c96657b14cff12ac3781292a55ed1df71075580152023-07-30 11:00:07210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0xdd190c39305d44376d583cf99a182f70c96657b14cff12ac3781292a55ed1df71075580152023-07-30 11:00:07210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0xdd190c39305d44376d583cf99a182f70c96657b14cff12ac3781292a55ed1df71075580152023-07-30 11:00:07210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0xdd190c39305d44376d583cf99a182f70c96657b14cff12ac3781292a55ed1df71075580152023-07-30 11:00:07210 days 13 hrs ago 0x554197e3593c2262a8ad0bfb22835f28f4bc384d 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c0 ETH
0x32f066cd3d4e1ec29379d00e81ab14c529670970734ca806fa91f0bf86365d691075579542023-07-30 10:58:05210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x32f066cd3d4e1ec29379d00e81ab14c529670970734ca806fa91f0bf86365d691075579542023-07-30 10:58:05210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x32f066cd3d4e1ec29379d00e81ab14c529670970734ca806fa91f0bf86365d691075579542023-07-30 10:58:05210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x32f066cd3d4e1ec29379d00e81ab14c529670970734ca806fa91f0bf86365d691075579542023-07-30 10:58:05210 days 13 hrs ago 0x554197e3593c2262a8ad0bfb22835f28f4bc384d 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c0 ETH
0x6f8a3b9bddb1e2480852e314e43b5cc1a13c80ebcb235969dd010f28f23c0e7e1075579182023-07-30 10:56:53210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x6f8a3b9bddb1e2480852e314e43b5cc1a13c80ebcb235969dd010f28f23c0e7e1075579182023-07-30 10:56:53210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x6f8a3b9bddb1e2480852e314e43b5cc1a13c80ebcb235969dd010f28f23c0e7e1075579182023-07-30 10:56:53210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x6f8a3b9bddb1e2480852e314e43b5cc1a13c80ebcb235969dd010f28f23c0e7e1075579182023-07-30 10:56:53210 days 13 hrs ago 0x554197e3593c2262a8ad0bfb22835f28f4bc384d 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c0 ETH
0x7cec4c382b2e0a748c68c1da83c69ed3650a818bd1ed86a7a1e07c759514c2e91075577962023-07-30 10:52:49210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x7cec4c382b2e0a748c68c1da83c69ed3650a818bd1ed86a7a1e07c759514c2e91075577962023-07-30 10:52:49210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x7cec4c382b2e0a748c68c1da83c69ed3650a818bd1ed86a7a1e07c759514c2e91075577962023-07-30 10:52:49210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x7cec4c382b2e0a748c68c1da83c69ed3650a818bd1ed86a7a1e07c759514c2e91075577962023-07-30 10:52:49210 days 13 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x5b0dce514b4aed993751d2cf7379b75df98603120 ETH
0x7cec4c382b2e0a748c68c1da83c69ed3650a818bd1ed86a7a1e07c759514c2e91075577962023-07-30 10:52:49210 days 13 hrs ago 0x554197e3593c2262a8ad0bfb22835f28f4bc384d 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c0 ETH
0x5cfe5e4a83f450dd35372788c383a82724c7e192fab0fede33d0392d19098e7f1075567962023-07-30 10:19:29210 days 14 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x092f6830eef16685ffb26efb783832d1cc4075d30 ETH
0x5cfe5e4a83f450dd35372788c383a82724c7e192fab0fede33d0392d19098e7f1075567962023-07-30 10:19:29210 days 14 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x092f6830eef16685ffb26efb783832d1cc4075d30 ETH
0x5cfe5e4a83f450dd35372788c383a82724c7e192fab0fede33d0392d19098e7f1075567962023-07-30 10:19:29210 days 14 hrs ago 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c 0x092f6830eef16685ffb26efb783832d1cc4075d30 ETH
0x5cfe5e4a83f450dd35372788c383a82724c7e192fab0fede33d0392d19098e7f1075567962023-07-30 10:19:29210 days 14 hrs ago 0xcfcb32ae3e6d8452dfe1a7975184b290d59830b3 0x0a3b938d51f1b6d7bf960a0cb6ac9f1154d0008c0 ETH
[ Download CSV Export 
Loading

Contract Source Code Verified (Exact Match)

Contract Name:
TarotSolidlyPriceOracleV2

Compiler Version
v0.5.16+commit.9c3226ce

Optimization Enabled:
Yes with 10000 runs

Other Settings:
default evmVersion
File 1 of 3 : TarotSolidlyPriceOracleV2.sol
pragma solidity =0.5.16;

import "./interfaces/ISolidlyBaseV1Pair.sol";
import "./interfaces/ITarotSolidlyPriceOracleV2.sol";

contract TarotSolidlyPriceOracleV2 is ITarotSolidlyPriceOracleV2 {
    uint32 public constant MIN_T = 900;

    function safe112(uint256 n) internal pure returns (uint112) {
        require(n < 2**112, "TarotSolidlyPriceOracleV2: SAFE112");
        return uint112(n);
    }

    function getResult(address pair) external returns (uint112 reserve0, uint112 reserve1, uint32 T) {
        (
            uint256 reserve0CumulativeCurrent,
            uint256 reserve1CumulativeCurrent,
            uint256 blockTimestampCurrent
        ) = ISolidlyBaseV1Pair(pair).currentCumulativePrices();
        uint256 observationLength = ISolidlyBaseV1Pair(pair).observationLength();
        (
            uint256 blockTimestampLast,
            uint256 reserve0CumulativeLast,
            uint256 reserve1CumulativeLast
        ) = ISolidlyBaseV1Pair(pair).observations(observationLength - 1);
        T = uint32(blockTimestampCurrent - blockTimestampLast);
        if (T < MIN_T) {
            (
                blockTimestampLast,
                reserve0CumulativeLast,
                reserve1CumulativeLast
            ) = ISolidlyBaseV1Pair(pair).observations(observationLength - 2);
            T = uint32(blockTimestampCurrent - blockTimestampLast);
        }
        reserve0 = safe112((reserve0CumulativeCurrent - reserve0CumulativeLast) / T);
        reserve1 = safe112((reserve1CumulativeCurrent - reserve1CumulativeLast) / T);
    }
}

File 2 of 3 : ISolidlyBaseV1Pair.sol
pragma solidity >=0.5;

interface ISolidlyBaseV1Pair {
    function getReserves()
        external
        view
        returns (
            uint112 _reserve0,
            uint112 _reserve1,
            uint32 _blockTimestampLast
        );

    function reserve0CumulativeLast() external view returns (uint256);

    function reserve1CumulativeLast() external view returns (uint256);

    function currentCumulativePrices()
        external
        view
        returns (
            uint256 reserve0Cumulative,
            uint256 reserve1Cumulative,
            uint256 blockTimestamp
        );

    function stable() external view returns (bool);

    function observationLength() external view returns (uint256);

    function observations(uint256) external view returns (uint256 timestamp, uint256 reserve0Cumulative, uint256 reserve1Cumulative);
}

File 3 of 3 : ITarotSolidlyPriceOracleV2.sol
pragma solidity >=0.5;

interface ITarotSolidlyPriceOracleV2 {
    function MIN_T() external pure returns (uint32);

    function getResult(address pair) external returns (uint112 reserve0, uint112 reserve1, uint32 T);
}

Settings
{
  "optimizer": {
    "enabled": true,
    "runs": 10000
  },
  "outputSelection": {
    "*": {
      "*": [
        "evm.bytecode",
        "evm.deployedBytecode",
        "devdoc",
        "userdoc",
        "metadata",
        "abi"
      ]
    }
  },
  "libraries": {}
}

Contract Security Audit

Contract ABI

[{"constant":true,"inputs":[],"name":"MIN_T","outputs":[{"internalType":"uint32","name":"","type":"uint32"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"internalType":"address","name":"pair","type":"address"}],"name":"getResult","outputs":[{"internalType":"uint112","name":"reserve0","type":"uint112"},{"internalType":"uint112","name":"reserve1","type":"uint112"},{"internalType":"uint32","name":"T","type":"uint32"}],"payable":false,"stateMutability":"nonpayable","type":"function"}]

608060405234801561001057600080fd5b50610478806100206000396000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c8063446a37e01461003b578063f51b5531146100a5575b600080fd5b61006e6004803603602081101561005157600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166100c6565b604080516dffffffffffffffffffffffffffff948516815292909316602083015263ffffffff168183015290519081900360600190f35b6100ad6103ae565b6040805163ffffffff9092168252519081900360200190f35b6000806000806000808673ffffffffffffffffffffffffffffffffffffffff16631df8c7176040518163ffffffff1660e01b815260040160606040518083038186803b15801561011557600080fd5b505afa158015610129573d6000803e3d6000fd5b505050506040513d606081101561013f57600080fd5b50805160208083015160409384015184517febeb31db0000000000000000000000000000000000000000000000000000000081529451939750909550935060009273ffffffffffffffffffffffffffffffffffffffff8b169263ebeb31db92600480840193919291829003018186803b1580156101bb57600080fd5b505afa1580156101cf573d6000803e3d6000fd5b505050506040513d60208110156101e557600080fd5b5051604080517f252c09d70000000000000000000000000000000000000000000000000000000081527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8301600482015290519192506000918291829173ffffffffffffffffffffffffffffffffffffffff8d169163252c09d7916024808301926060929190829003018186803b15801561027f57600080fd5b505afa158015610293573d6000803e3d6000fd5b505050506040513d60608110156102a957600080fd5b50805160208201516040909201518188039a50909450909250905061038463ffffffff8916101561036e578a73ffffffffffffffffffffffffffffffffffffffff1663252c09d7600286036040518263ffffffff1660e01b81526004018082815260200191505060606040518083038186803b15801561032857600080fd5b505afa15801561033c573d6000803e3d6000fd5b505050506040513d606081101561035257600080fd5b50805160208201516040909201518188039a5090945090925090505b6103888863ffffffff168389038161038257fe5b046103b4565b995061039e8863ffffffff168288038161038257fe5b9850505050505050509193909250565b61038481565b60006e010000000000000000000000000000821061041d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806104226022913960400191505060405180910390fd5b509056fe5461726f74536f6c69646c7950726963654f7261636c6556323a2053414645313132a265627a7a7231582036fff6f57eaa5fc9d25d80102b4b4294057d995dec474c0c1518776b425b8b9d64736f6c63430005100032

Deployed Bytecode

0x608060405234801561001057600080fd5b50600436106100365760003560e01c8063446a37e01461003b578063f51b5531146100a5575b600080fd5b61006e6004803603602081101561005157600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166100c6565b604080516dffffffffffffffffffffffffffff948516815292909316602083015263ffffffff168183015290519081900360600190f35b6100ad6103ae565b6040805163ffffffff9092168252519081900360200190f35b6000806000806000808673ffffffffffffffffffffffffffffffffffffffff16631df8c7176040518163ffffffff1660e01b815260040160606040518083038186803b15801561011557600080fd5b505afa158015610129573d6000803e3d6000fd5b505050506040513d606081101561013f57600080fd5b50805160208083015160409384015184517febeb31db0000000000000000000000000000000000000000000000000000000081529451939750909550935060009273ffffffffffffffffffffffffffffffffffffffff8b169263ebeb31db92600480840193919291829003018186803b1580156101bb57600080fd5b505afa1580156101cf573d6000803e3d6000fd5b505050506040513d60208110156101e557600080fd5b5051604080517f252c09d70000000000000000000000000000000000000000000000000000000081527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8301600482015290519192506000918291829173ffffffffffffffffffffffffffffffffffffffff8d169163252c09d7916024808301926060929190829003018186803b15801561027f57600080fd5b505afa158015610293573d6000803e3d6000fd5b505050506040513d60608110156102a957600080fd5b50805160208201516040909201518188039a50909450909250905061038463ffffffff8916101561036e578a73ffffffffffffffffffffffffffffffffffffffff1663252c09d7600286036040518263ffffffff1660e01b81526004018082815260200191505060606040518083038186803b15801561032857600080fd5b505afa15801561033c573d6000803e3d6000fd5b505050506040513d606081101561035257600080fd5b50805160208201516040909201518188039a5090945090925090505b6103888863ffffffff168389038161038257fe5b046103b4565b995061039e8863ffffffff168288038161038257fe5b9850505050505050509193909250565b61038481565b60006e010000000000000000000000000000821061041d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806104226022913960400191505060405180910390fd5b509056fe5461726f74536f6c69646c7950726963654f7261636c6556323a2053414645313132a265627a7a7231582036fff6f57eaa5fc9d25d80102b4b4294057d995dec474c0c1518776b425b8b9d64736f6c63430005100032

Block Transaction Difficulty Gas Used Reward
Block Uncle Number Difficulty Gas Used Reward
Loading
Loading
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.