Sponsored Link:   WELL – WORKING HEALTHCARE U.S. PLATFORM - RAISED $3M IN PRE-ICO – JOIN NOW WITH 40% BONUS
Contract Overview | DigitexFuturesToken
ETH Balance: 0.291544 Ether
ETH USD Value: $257.71 (@ $883.96/ETH)
No Of Transactions: 14881 txns
Token Tracker 0x1c83501478f1320977047008496dacbd60bb15ef
  Latest 25 txns from a total Of 14881 transactions (+2 PendingTxns) View All

TxHash Age From To Value [TxFee]
0xd2a348099edb75d88a7cc48be172ac424eec1c870818c08c7d2d6318ded330f0(pending)6 mins ago0x507ff6b56e27d29de717717823b1de6ab11d36b5  IN  0x1c83501478f1320977047008496dacbd60bb15ef0.07 Ether(pending)
0xed900ba15cba5fc43d814d21b5dc1806287d347bdc14a579874c9d14dd8fc568(pending)13 mins ago0x507ff6b56e27d29de717717823b1de6ab11d36b5  IN  0x1c83501478f1320977047008496dacbd60bb15ef0.07 Ether(pending)
0x9e28448606164b0eaa801bfc3ac7e7ae1c9c65e3f58ecb9e76ad119cf7360ad631 mins ago0xaf67724420327f173fe3d7c90a22a49c2fdbc661  IN   DigitexFuturesToken0 Ether0.000864654
0x3f6d1d42b2f8ff1377cfb05f99738a4e8a949f0d1513fa90c7867ff3a4fb1e731 hr 53 mins ago0xaf67724420327f173fe3d7c90a22a49c2fdbc661  IN   DigitexFuturesToken0 Ether0.00112348
0x3b3d95a6601acf0d31feba0ec1c19fc8f6c8c03353213bb3b0f27b1116ecfb894 hrs 48 mins ago0xa58117e08d1b5519d2ee55ab07cdfd333831551f  IN   DigitexFuturesToken0 Ether0.00117831
0xb4c9997466cdbaa635a7f60fd53256e52ee11dfbadfad2902e6e97aeff5559796 hrs 4 mins ago0xff0f3e2315521fd27a226040c6d0d6fe4d239a7b  IN   DigitexFuturesToken0 Ether0.00018244
0xef88d38264a988b3b34a8333caccc05639f887f128f893189002db896c7b97996 hrs 53 mins ago0xff0f3e2315521fd27a226040c6d0d6fe4d239a7b  IN   DigitexFuturesToken0 Ether0.00016
0x68644060b7305b719796ed0742573b9b80998606fbbb7540a6918a36e0ec886e7 hrs 18 mins ago0x7d0bad5c319f995531475d2dcba3c947aea10cd6  IN   DigitexFuturesToken0 Ether0.00112348
0x0a660d01af65586c2793b1771eac24a4d0aa2515ab917d577617f739df59f0da7 hrs 27 mins ago0xff0f3e2315521fd27a226040c6d0d6fe4d239a7b  IN   DigitexFuturesToken0 Ether0.00016
0x4e4488e09f8cf6faad4e7814910ee6c2c0cb9269d15503936a595ada48495db88 hrs 4 mins ago0x88615a37e179e096a01f9fdc6cf947b68091279f  IN   DigitexFuturesToken0 Ether0.00291772
0x03b50708d84fa62ff4530a3b6aee1c65613ad45becac3abb48fe4495553089f88 hrs 31 mins ago0xe8f043b2d0f4bf67a0e5f7a36803cdf66bec51af  IN   DigitexFuturesToken0 Ether0.001280362
0xf7bc0231857005934ebaf7bfb8092b907dd1b3222776f9f90de027a648f4913d9 hrs 19 mins ago0xb0890bb90f11193e30655c4c978e91a79cd60b50  IN   DigitexFuturesToken0 Ether0.00117831
0xfe1bab4236a3ec088f64e5e7ac021352af4073be0d8599c58ebb3ba003c2744f9 hrs 54 mins ago0x0e8c3d5d7e2714b3e8176785a665fd01d23977f8  IN   DigitexFuturesToken0 Ether0.002977222
0xec969b946cf6d9d19609712e82a90d1c3050f97efde6a5ac68a9ae4cb3b8bcf910 hrs 7 mins ago0x2dc651f488c597f7ab241a04d2695616ef7e2d9d  IN   DigitexFuturesToken0 Ether0.000495624
0xf9ec593a0dbd1d6a260a489a13b5cea53b95d55fa89ac448af92311c563c6de110 hrs 46 mins ago0xd1b7a0335fc703e4538817c3551b602201fcce28  IN   DigitexFuturesToken0 Ether0.0018277
0x687fa8f3cec2b5fa5f18a72fcbb8044d196d77081425891672df886661f77a8612 hrs 55 mins ago0xc697982146510f33f513b01156366f7f27c0b6a5  IN   DigitexFuturesToken0 Ether0.001793472
0x5fc3e050455cdd50c366b68cc31dc2a325311fd309a399e72fac03157e97831413 hrs 6 mins ago0x362fcd9a5572615f355ead6d29ee34ba2643de36  IN   DigitexFuturesToken0 Ether0.004088898
0x8ec6672c2008f30c186e95040f772085ca3ea836219d31d9338e6c7b390589df15 hrs 4 mins ago0xe0253e78870256811294120bedbf958a448655c5  IN   DigitexFuturesToken0 Ether0.002022360423
0x9ca9b3a751e2bbcfb5d24513c82ed768ca369b71c8cc5ad9a5bc120a9b5635ec15 hrs 59 mins ago0xb636f777d87ec9fe39754c01dd6b2e5a53ccd92f  IN   DigitexFuturesToken0 Ether0.001682886
0xb2b5251431581eb8570f70696f4c80927672c48937b78a95ed86e72d3efb91cb16 hrs 4 mins ago0x232d63457514702130fcf9e63316e2e01d665d92  IN   DigitexFuturesToken0 Ether0.002924376
0xdbad1549813fcf54229923689c7d935a1fcd8e91ae0a9e2b6a047ca271454c4f18 hrs 43 mins ago0x92d604992e0ec46d907339aa7fb899ecc2829a60  IN   DigitexFuturesToken0 Ether0.000329904
0xc7a43337beeb4e96eee910ba02bb1fdfb7b877c7ba10f1eee14a3b70f7c2ab3218 hrs 48 mins ago0x92d604992e0ec46d907339aa7fb899ecc2829a60  IN   DigitexFuturesToken0 Ether0.00032888
0xa1cfcc04c2d74cd7e63b486e9be08b3488062e842c0b6e3c309bc0f7f1caf9fc18 hrs 53 mins ago0x92d604992e0ec46d907339aa7fb899ecc2829a60  IN   DigitexFuturesToken0 Ether0.000448368
0x3bd885854080b223483bded1516724f997576e291c3bf765797292444e7e020620 hrs 32 mins ago0x134fa735dcbd8d3caca079f14aebe492d73fa046  IN   DigitexFuturesToken0 Ether0.001884528
0x8d6d7756e7ef68ac72262a90465810177a0272b32f9764f7e3158209f637338120 hrs 33 mins ago0x134fa735dcbd8d3caca079f14aebe492d73fa046  IN   DigitexFuturesToken0 Ether0.0024666
[ Download CSV Export  ] 
 Internal Transactions as a result of Contract Execution
  Latest 25 Internal Txns, Click here to View More View All
ParentTxHash Block Age From To Value
0x17e4d8440957e07325c728d4273361cc74fc1015aa9e0b21bbe922d96324bf4c50959285 days 6 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x7128623ae893aba6932be8e8319254cfa283c5da8e45c26c8165044b60db426750954505 days 7 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x642009ca9a803d1f22f989febc66c6cd5698fb9badcf3b2279a67a84253f90cb50897556 days 7 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0xb298361e13668776d7e7c3c07244e70c302f86228f61598955c48df7c9cad0a250894886 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0xd331766f3557082c34bff72f30e7cafc452bc4406a93ecd0890c169f2f197bfa50838547 days 7 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x97c39a4d2a0ed07883e956645549656552f8f3b8f2cb659f355a7ef98e0ca63050835697 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x143289000758f7649e7d4d5f13e2072209607a4cab42447d2b02936393b1adbe50778998 days 7 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0xe886aac7fcfe7688398b677cd4cae2cab0665f5d2e994aa9dd1fdfd827499c7950776118 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0xc32f3788fe5171864ca0686647fbfb367463494d02343f168323d2bb143c2a1350719509 days 7 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x45a4420a5784e904c0606d0f2064e6e3230ea46436bca062fbf885982d2b2f1450716629 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0xc9ed94e81e596bb9e1935c8c069cb6457e2f5f9688fd628e361148cac8e03543506593510 days 7 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x38e1b9efbadcd183fea7afb92ff779fb36f0e75ee3bbe284724e9bc7ebf718fd506564410 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0xc9a4c1595ac5787a7c36089234b07702fbf16eda5f7e3c089de3c72a1158801c506000811 days 7 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x22f37278afa1e941b5188cc7958df4bfd13f62d2fa8400ffe1f3170aa91cde8d505974711 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x539ea8c1cb9fdd4b0e5736a01247a524e606ed49eab0d6983c79ab4af2a5087a505398212 days 7 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x340d184a28947daf4918663cdf0c01e90f3dc7c36ca8716f3532032e62555585505357112 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x7ae361f5798c3b9c37005091de44ff5469679f272d234c63897ccf3857ee7ac2504803913 days 7 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x49160ebca898f6b3eff16fb583bfd9b2bac926eae9adde1ab5b17d129b07eb03504764713 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0xb5817f7544f3bf9230be5477eb2ae68fe8bd5d23fc1064f2e45a4b49213d8dcc504208614 days 7 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x867e75c33667fbce364b9783ac3cd3fadf011740160fb7bba7558f150670c446504167814 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x0c72527812aa57994429d1b398236bfb512bd1063ea698ab622a4a9ef1148153503614915 days 7 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x302a56b3313d6c2347ff855b15cf16611164a28be40b8dbb2ef9cf6d9c8a448a503577015 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x646c2ceba5bfc91a39a9e6711489ef240dc0de738606cd0909be9a87a528adb2502991516 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x34f892489086ce8caaa1ac233f9cd815f8897b1e583ab857cb965a5ef46980e8502977816 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
0x8729b1469b100561c24a3e4d841cc2d92485ac15b13efab9cced568cce94fee1502396917 days 8 hrs ago0x1c83501478f1320977047008496dacbd60bb15ef0x3dbdc81a6edc94c720b0b88fb65dbd7e395fdcf60.0040092 Ether
[ Download CSV Export  ] 
Contract Source Code Verified
Contract Name: DGTX
Compiler Version: v0.4.19+commit.c4cbbb05
Optimization Enabled: Yes
Runs (Optimiser):  200



  Contract Source Code   Find Similiar Contracts
pragma solidity ^0.4.18;


/**
 * @title ERC20Basic
 * @dev Simpler version of ERC20 interface
 * @dev see https://github.com/ethereum/EIPs/issues/179
 */
contract ERC20Basic {
  uint256 public totalSupply;
  function balanceOf(address who) public view returns (uint256);
  function transfer(address to, uint256 value) public returns (bool);
  event Transfer(address indexed from, address indexed to, uint256 value);
}



/**
 * @title Ownable
 * @dev The Ownable contract has an owner address, and provides basic authorization control
 * functions, this simplifies the implementation of "user permissions".
 */
contract Ownable {
  address public owner;


  event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);


  /**
   * @dev The Ownable constructor sets the original `owner` of the contract to the sender
   * account.
   */
  function Ownable() public {
    owner = msg.sender;
  }


  /**
   * @dev Throws if called by any account other than the owner.
   */
  modifier onlyOwner() {
    require(msg.sender == owner);
    _;
  }


  /**
   * @dev Allows the current owner to transfer control of the contract to a newOwner.
   * @param newOwner The address to transfer ownership to.
   */
  function transferOwnership(address newOwner) public onlyOwner {
    require(newOwner != address(0));
    OwnershipTransferred(owner, newOwner);
    owner = newOwner;
  }

}


//import "github.com/oraclize/ethereum-api/oraclizeAPI.sol";
// <ORACLIZE_API>
/*
Copyright (c) 2015-2016 Oraclize SRL
Copyright (c) 2016 Oraclize LTD



Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:



The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.



THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/

//please import oraclizeAPI_pre0.4.sol when solidity < 0.4.0

contract OraclizeI {
    address public cbAddress;
    function query(uint _timestamp, string _datasource, string _arg) payable returns (bytes32 _id);
    function query_withGasLimit(uint _timestamp, string _datasource, string _arg, uint _gaslimit) payable returns (bytes32 _id);
    function query2(uint _timestamp, string _datasource, string _arg1, string _arg2) payable returns (bytes32 _id);
    function query2_withGasLimit(uint _timestamp, string _datasource, string _arg1, string _arg2, uint _gaslimit) payable returns (bytes32 _id);
    function queryN(uint _timestamp, string _datasource, bytes _argN) payable returns (bytes32 _id);
    function queryN_withGasLimit(uint _timestamp, string _datasource, bytes _argN, uint _gaslimit) payable returns (bytes32 _id);
    function getPrice(string _datasource) returns (uint _dsprice);
    function getPrice(string _datasource, uint gaslimit) returns (uint _dsprice);
    function useCoupon(string _coupon);
    function setProofType(byte _proofType);
    function setConfig(bytes32 _config);
    function setCustomGasPrice(uint _gasPrice);
    function randomDS_getSessionPubKeyHash() returns(bytes32);
}
contract OraclizeAddrResolverI {
    function getAddress() returns (address _addr);
}
contract usingOraclize {
    uint constant day = 60*60*24;
    uint constant week = 60*60*24*7;
    uint constant month = 60*60*24*30;
    byte constant proofType_NONE = 0x00;
    byte constant proofType_TLSNotary = 0x10;
    byte constant proofType_Android = 0x20;
    byte constant proofType_Ledger = 0x30;
    byte constant proofType_Native = 0xF0;
    byte constant proofStorage_IPFS = 0x01;
    uint8 constant networkID_auto = 0;
    uint8 constant networkID_mainnet = 1;
    uint8 constant networkID_testnet = 2;
    uint8 constant networkID_morden = 2;
    uint8 constant networkID_consensys = 161;

    OraclizeAddrResolverI OAR;

    OraclizeI oraclize;
    modifier oraclizeAPI {
        if((address(OAR)==0)||(getCodeSize(address(OAR))==0))
            oraclize_setNetwork(networkID_auto);

        if(address(oraclize) != OAR.getAddress())
            oraclize = OraclizeI(OAR.getAddress());

        _;
    }
    modifier coupon(string code){
        oraclize = OraclizeI(OAR.getAddress());
        oraclize.useCoupon(code);
        _;
    }

    function oraclize_setNetwork(uint8 networkID) internal returns(bool){
        if (getCodeSize(0x1d3B2638a7cC9f2CB3D298A3DA7a90B67E5506ed)>0){ //mainnet
            OAR = OraclizeAddrResolverI(0x1d3B2638a7cC9f2CB3D298A3DA7a90B67E5506ed);
            oraclize_setNetworkName("eth_mainnet");
            return true;
        }
        if (getCodeSize(0xc03A2615D5efaf5F49F60B7BB6583eaec212fdf1)>0){ //ropsten testnet
            OAR = OraclizeAddrResolverI(0xc03A2615D5efaf5F49F60B7BB6583eaec212fdf1);
            oraclize_setNetworkName("eth_ropsten3");
            return true;
        }
        if (getCodeSize(0xB7A07BcF2Ba2f2703b24C0691b5278999C59AC7e)>0){ //kovan testnet
            OAR = OraclizeAddrResolverI(0xB7A07BcF2Ba2f2703b24C0691b5278999C59AC7e);
            oraclize_setNetworkName("eth_kovan");
            return true;
        }
        if (getCodeSize(0x146500cfd35B22E4A392Fe0aDc06De1a1368Ed48)>0){ //rinkeby testnet
            OAR = OraclizeAddrResolverI(0x146500cfd35B22E4A392Fe0aDc06De1a1368Ed48);
            oraclize_setNetworkName("eth_rinkeby");
            return true;
        }
        if (getCodeSize(0x6f485C8BF6fc43eA212E93BBF8ce046C7f1cb475)>0){ //ethereum-bridge
            OAR = OraclizeAddrResolverI(0x6f485C8BF6fc43eA212E93BBF8ce046C7f1cb475);
            return true;
        }
        if (getCodeSize(0x20e12A1F859B3FeaE5Fb2A0A32C18F5a65555bBF)>0){ //ether.camp ide
            OAR = OraclizeAddrResolverI(0x20e12A1F859B3FeaE5Fb2A0A32C18F5a65555bBF);
            return true;
        }
        if (getCodeSize(0x51efaF4c8B3C9AfBD5aB9F4bbC82784Ab6ef8fAA)>0){ //browser-solidity
            OAR = OraclizeAddrResolverI(0x51efaF4c8B3C9AfBD5aB9F4bbC82784Ab6ef8fAA);
            return true;
        }
        return false;
    }

    function __callback(bytes32 myid, string result) {
        __callback(myid, result, new bytes(0));
    }
    function __callback(bytes32 myid, string result, bytes proof) {
    }

    function oraclize_useCoupon(string code) oraclizeAPI internal {
        oraclize.useCoupon(code);
    }

    function oraclize_getPrice(string datasource) oraclizeAPI internal returns (uint){
        return oraclize.getPrice(datasource);
    }

    function oraclize_getPrice(string datasource, uint gaslimit) oraclizeAPI internal returns (uint){
        return oraclize.getPrice(datasource, gaslimit);
    }

    function oraclize_query(string datasource, string arg) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource);
        if (price > 1 ether + tx.gasprice*200000) return 0; // unexpectedly high price
        return oraclize.query.value(price)(0, datasource, arg);
    }
    function oraclize_query(uint timestamp, string datasource, string arg) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource);
        if (price > 1 ether + tx.gasprice*200000) return 0; // unexpectedly high price
        return oraclize.query.value(price)(timestamp, datasource, arg);
    }
    function oraclize_query(uint timestamp, string datasource, string arg, uint gaslimit) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource, gaslimit);
        if (price > 1 ether + tx.gasprice*gaslimit) return 0; // unexpectedly high price
        return oraclize.query_withGasLimit.value(price)(timestamp, datasource, arg, gaslimit);
    }
    function oraclize_query(string datasource, string arg, uint gaslimit) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource, gaslimit);
        if (price > 1 ether + tx.gasprice*gaslimit) return 0; // unexpectedly high price
        return oraclize.query_withGasLimit.value(price)(0, datasource, arg, gaslimit);
    }
    function oraclize_query(string datasource, string arg1, string arg2) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource);
        if (price > 1 ether + tx.gasprice*200000) return 0; // unexpectedly high price
        return oraclize.query2.value(price)(0, datasource, arg1, arg2);
    }
    function oraclize_query(uint timestamp, string datasource, string arg1, string arg2) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource);
        if (price > 1 ether + tx.gasprice*200000) return 0; // unexpectedly high price
        return oraclize.query2.value(price)(timestamp, datasource, arg1, arg2);
    }
    function oraclize_query(uint timestamp, string datasource, string arg1, string arg2, uint gaslimit) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource, gaslimit);
        if (price > 1 ether + tx.gasprice*gaslimit) return 0; // unexpectedly high price
        return oraclize.query2_withGasLimit.value(price)(timestamp, datasource, arg1, arg2, gaslimit);
    }
    function oraclize_query(string datasource, string arg1, string arg2, uint gaslimit) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource, gaslimit);
        if (price > 1 ether + tx.gasprice*gaslimit) return 0; // unexpectedly high price
        return oraclize.query2_withGasLimit.value(price)(0, datasource, arg1, arg2, gaslimit);
    }
    function oraclize_query(string datasource, string[] argN) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource);
        if (price > 1 ether + tx.gasprice*200000) return 0; // unexpectedly high price
        bytes memory args = stra2cbor(argN);
        return oraclize.queryN.value(price)(0, datasource, args);
    }
    function oraclize_query(uint timestamp, string datasource, string[] argN) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource);
        if (price > 1 ether + tx.gasprice*200000) return 0; // unexpectedly high price
        bytes memory args = stra2cbor(argN);
        return oraclize.queryN.value(price)(timestamp, datasource, args);
    }
    function oraclize_query(uint timestamp, string datasource, string[] argN, uint gaslimit) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource, gaslimit);
        if (price > 1 ether + tx.gasprice*gaslimit) return 0; // unexpectedly high price
        bytes memory args = stra2cbor(argN);
        return oraclize.queryN_withGasLimit.value(price)(timestamp, datasource, args, gaslimit);
    }
    function oraclize_query(string datasource, string[] argN, uint gaslimit) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource, gaslimit);
        if (price > 1 ether + tx.gasprice*gaslimit) return 0; // unexpectedly high price
        bytes memory args = stra2cbor(argN);
        return oraclize.queryN_withGasLimit.value(price)(0, datasource, args, gaslimit);
    }
    function oraclize_query(string datasource, string[1] args) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](1);
        dynargs[0] = args[0];
        return oraclize_query(datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, string[1] args) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](1);
        dynargs[0] = args[0];
        return oraclize_query(timestamp, datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, string[1] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](1);
        dynargs[0] = args[0];
        return oraclize_query(timestamp, datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, string[1] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](1);
        dynargs[0] = args[0];
        return oraclize_query(datasource, dynargs, gaslimit);
    }

    function oraclize_query(string datasource, string[2] args) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](2);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        return oraclize_query(datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, string[2] args) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](2);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        return oraclize_query(timestamp, datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, string[2] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](2);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        return oraclize_query(timestamp, datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, string[2] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](2);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        return oraclize_query(datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, string[3] args) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](3);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        return oraclize_query(datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, string[3] args) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](3);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        return oraclize_query(timestamp, datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, string[3] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](3);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        return oraclize_query(timestamp, datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, string[3] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](3);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        return oraclize_query(datasource, dynargs, gaslimit);
    }

    function oraclize_query(string datasource, string[4] args) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](4);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        return oraclize_query(datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, string[4] args) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](4);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        return oraclize_query(timestamp, datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, string[4] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](4);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        return oraclize_query(timestamp, datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, string[4] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](4);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        return oraclize_query(datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, string[5] args) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](5);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        dynargs[4] = args[4];
        return oraclize_query(datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, string[5] args) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](5);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        dynargs[4] = args[4];
        return oraclize_query(timestamp, datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, string[5] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](5);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        dynargs[4] = args[4];
        return oraclize_query(timestamp, datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, string[5] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        string[] memory dynargs = new string[](5);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        dynargs[4] = args[4];
        return oraclize_query(datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, bytes[] argN) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource);
        if (price > 1 ether + tx.gasprice*200000) return 0; // unexpectedly high price
        bytes memory args = ba2cbor(argN);
        return oraclize.queryN.value(price)(0, datasource, args);
    }
    function oraclize_query(uint timestamp, string datasource, bytes[] argN) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource);
        if (price > 1 ether + tx.gasprice*200000) return 0; // unexpectedly high price
        bytes memory args = ba2cbor(argN);
        return oraclize.queryN.value(price)(timestamp, datasource, args);
    }
    function oraclize_query(uint timestamp, string datasource, bytes[] argN, uint gaslimit) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource, gaslimit);
        if (price > 1 ether + tx.gasprice*gaslimit) return 0; // unexpectedly high price
        bytes memory args = ba2cbor(argN);
        return oraclize.queryN_withGasLimit.value(price)(timestamp, datasource, args, gaslimit);
    }
    function oraclize_query(string datasource, bytes[] argN, uint gaslimit) oraclizeAPI internal returns (bytes32 id){
        uint price = oraclize.getPrice(datasource, gaslimit);
        if (price > 1 ether + tx.gasprice*gaslimit) return 0; // unexpectedly high price
        bytes memory args = ba2cbor(argN);
        return oraclize.queryN_withGasLimit.value(price)(0, datasource, args, gaslimit);
    }
    function oraclize_query(string datasource, bytes[1] args) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](1);
        dynargs[0] = args[0];
        return oraclize_query(datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, bytes[1] args) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](1);
        dynargs[0] = args[0];
        return oraclize_query(timestamp, datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, bytes[1] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](1);
        dynargs[0] = args[0];
        return oraclize_query(timestamp, datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, bytes[1] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](1);
        dynargs[0] = args[0];
        return oraclize_query(datasource, dynargs, gaslimit);
    }

    function oraclize_query(string datasource, bytes[2] args) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](2);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        return oraclize_query(datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, bytes[2] args) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](2);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        return oraclize_query(timestamp, datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, bytes[2] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](2);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        return oraclize_query(timestamp, datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, bytes[2] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](2);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        return oraclize_query(datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, bytes[3] args) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](3);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        return oraclize_query(datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, bytes[3] args) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](3);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        return oraclize_query(timestamp, datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, bytes[3] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](3);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        return oraclize_query(timestamp, datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, bytes[3] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](3);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        return oraclize_query(datasource, dynargs, gaslimit);
    }

    function oraclize_query(string datasource, bytes[4] args) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](4);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        return oraclize_query(datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, bytes[4] args) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](4);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        return oraclize_query(timestamp, datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, bytes[4] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](4);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        return oraclize_query(timestamp, datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, bytes[4] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](4);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        return oraclize_query(datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, bytes[5] args) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](5);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        dynargs[4] = args[4];
        return oraclize_query(datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, bytes[5] args) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](5);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        dynargs[4] = args[4];
        return oraclize_query(timestamp, datasource, dynargs);
    }
    function oraclize_query(uint timestamp, string datasource, bytes[5] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](5);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        dynargs[4] = args[4];
        return oraclize_query(timestamp, datasource, dynargs, gaslimit);
    }
    function oraclize_query(string datasource, bytes[5] args, uint gaslimit) oraclizeAPI internal returns (bytes32 id) {
        bytes[] memory dynargs = new bytes[](5);
        dynargs[0] = args[0];
        dynargs[1] = args[1];
        dynargs[2] = args[2];
        dynargs[3] = args[3];
        dynargs[4] = args[4];
        return oraclize_query(datasource, dynargs, gaslimit);
    }

    function oraclize_cbAddress() oraclizeAPI internal returns (address){
        return oraclize.cbAddress();
    }
    function oraclize_setProof(byte proofP) oraclizeAPI internal {
        return oraclize.setProofType(proofP);
    }
    function oraclize_setCustomGasPrice(uint gasPrice) oraclizeAPI internal {
        return oraclize.setCustomGasPrice(gasPrice);
    }
    function oraclize_setConfig(bytes32 config) oraclizeAPI internal {
        return oraclize.setConfig(config);
    }

    function oraclize_randomDS_getSessionPubKeyHash() oraclizeAPI internal returns (bytes32){
        return oraclize.randomDS_getSessionPubKeyHash();
    }

    function getCodeSize(address _addr) constant internal returns(uint _size) {
        assembly {
            _size := extcodesize(_addr)
        }
    }

    function parseAddr(string _a) internal returns (address){
        bytes memory tmp = bytes(_a);
        uint160 iaddr = 0;
        uint160 b1;
        uint160 b2;
        for (uint i=2; i<2+2*20; i+=2){
            iaddr *= 256;
            b1 = uint160(tmp[i]);
            b2 = uint160(tmp[i+1]);
            if ((b1 >= 97)&&(b1 <= 102)) b1 -= 87;
            else if ((b1 >= 65)&&(b1 <= 70)) b1 -= 55;
            else if ((b1 >= 48)&&(b1 <= 57)) b1 -= 48;
            if ((b2 >= 97)&&(b2 <= 102)) b2 -= 87;
            else if ((b2 >= 65)&&(b2 <= 70)) b2 -= 55;
            else if ((b2 >= 48)&&(b2 <= 57)) b2 -= 48;
            iaddr += (b1*16+b2);
        }
        return address(iaddr);
    }

    function strCompare(string _a, string _b) internal returns (int) {
        bytes memory a = bytes(_a);
        bytes memory b = bytes(_b);
        uint minLength = a.length;
        if (b.length < minLength) minLength = b.length;
        for (uint i = 0; i < minLength; i ++)
            if (a[i] < b[i])
                return -1;
            else if (a[i] > b[i])
                return 1;
        if (a.length < b.length)
            return -1;
        else if (a.length > b.length)
            return 1;
        else
            return 0;
    }

    function indexOf(string _haystack, string _needle) internal returns (int) {
        bytes memory h = bytes(_haystack);
        bytes memory n = bytes(_needle);
        if(h.length < 1 || n.length < 1 || (n.length > h.length))
            return -1;
        else if(h.length > (2**128 -1))
            return -1;
        else
        {
            uint subindex = 0;
            for (uint i = 0; i < h.length; i ++)
            {
                if (h[i] == n[0])
                {
                    subindex = 1;
                    while(subindex < n.length && (i + subindex) < h.length && h[i + subindex] == n[subindex])
                    {
                        subindex++;
                    }
                    if(subindex == n.length)
                        return int(i);
                }
            }
            return -1;
        }
    }

    function strConcat(string _a, string _b, string _c, string _d, string _e) internal returns (string) {
        bytes memory _ba = bytes(_a);
        bytes memory _bb = bytes(_b);
        bytes memory _bc = bytes(_c);
        bytes memory _bd = bytes(_d);
        bytes memory _be = bytes(_e);
        string memory abcde = new string(_ba.length + _bb.length + _bc.length + _bd.length + _be.length);
        bytes memory babcde = bytes(abcde);
        uint k = 0;
        for (uint i = 0; i < _ba.length; i++) babcde[k++] = _ba[i];
        for (i = 0; i < _bb.length; i++) babcde[k++] = _bb[i];
        for (i = 0; i < _bc.length; i++) babcde[k++] = _bc[i];
        for (i = 0; i < _bd.length; i++) babcde[k++] = _bd[i];
        for (i = 0; i < _be.length; i++) babcde[k++] = _be[i];
        return string(babcde);
    }

    function strConcat(string _a, string _b, string _c, string _d) internal returns (string) {
        return strConcat(_a, _b, _c, _d, "");
    }

    function strConcat(string _a, string _b, string _c) internal returns (string) {
        return strConcat(_a, _b, _c, "", "");
    }

    function strConcat(string _a, string _b) internal returns (string) {
        return strConcat(_a, _b, "", "", "");
    }

    // parseInt
    function parseInt(string _a) internal returns (uint) {
        return parseInt(_a, 0);
    }

    // parseInt(parseFloat*10^_b)
    function parseInt(string _a, uint _b) internal returns (uint) {
        bytes memory bresult = bytes(_a);
        uint mint = 0;
        bool decimals = false;
        for (uint i=0; i<bresult.length; i++){
            if ((bresult[i] >= 48)&&(bresult[i] <= 57)){
                if (decimals){
                   if (_b == 0) break;
                    else _b--;
                }
                mint *= 10;
                mint += uint(bresult[i]) - 48;
            } else if (bresult[i] == 46) decimals = true;
        }
        if (_b > 0) mint *= 10**_b;
        return mint;
    }

    function uint2str(uint i) internal returns (string){
        if (i == 0) return "0";
        uint j = i;
        uint len;
        while (j != 0){
            len++;
            j /= 10;
        }
        bytes memory bstr = new bytes(len);
        uint k = len - 1;
        while (i != 0){
            bstr[k--] = byte(48 + i % 10);
            i /= 10;
        }
        return string(bstr);
    }

    function stra2cbor(string[] arr) internal returns (bytes) {
            uint arrlen = arr.length;

            // get correct cbor output length
            uint outputlen = 0;
            bytes[] memory elemArray = new bytes[](arrlen);
            for (uint i = 0; i < arrlen; i++) {
                elemArray[i] = (bytes(arr[i]));
                outputlen += elemArray[i].length + (elemArray[i].length - 1)/23 + 3; //+3 accounts for paired identifier types
            }
            uint ctr = 0;
            uint cborlen = arrlen + 0x80;
            outputlen += byte(cborlen).length;
            bytes memory res = new bytes(outputlen);

            while (byte(cborlen).length > ctr) {
                res[ctr] = byte(cborlen)[ctr];
                ctr++;
            }
            for (i = 0; i < arrlen; i++) {
                res[ctr] = 0x5F;
                ctr++;
                for (uint x = 0; x < elemArray[i].length; x++) {
                    // if there's a bug with larger strings, this may be the culprit
                    if (x % 23 == 0) {
                        uint elemcborlen = elemArray[i].length - x >= 24 ? 23 : elemArray[i].length - x;
                        elemcborlen += 0x40;
                        uint lctr = ctr;
                        while (byte(elemcborlen).length > ctr - lctr) {
                            res[ctr] = byte(elemcborlen)[ctr - lctr];
                            ctr++;
                        }
                    }
                    res[ctr] = elemArray[i][x];
                    ctr++;
                }
                res[ctr] = 0xFF;
                ctr++;
            }
            return res;
        }

    function ba2cbor(bytes[] arr) internal returns (bytes) {
            uint arrlen = arr.length;

            // get correct cbor output length
            uint outputlen = 0;
            bytes[] memory elemArray = new bytes[](arrlen);
            for (uint i = 0; i < arrlen; i++) {
                elemArray[i] = (bytes(arr[i]));
                outputlen += elemArray[i].length + (elemArray[i].length - 1)/23 + 3; //+3 accounts for paired identifier types
            }
            uint ctr = 0;
            uint cborlen = arrlen + 0x80;
            outputlen += byte(cborlen).length;
            bytes memory res = new bytes(outputlen);

            while (byte(cborlen).length > ctr) {
                res[ctr] = byte(cborlen)[ctr];
                ctr++;
            }
            for (i = 0; i < arrlen; i++) {
                res[ctr] = 0x5F;
                ctr++;
                for (uint x = 0; x < elemArray[i].length; x++) {
                    // if there's a bug with larger strings, this may be the culprit
                    if (x % 23 == 0) {
                        uint elemcborlen = elemArray[i].length - x >= 24 ? 23 : elemArray[i].length - x;
                        elemcborlen += 0x40;
                        uint lctr = ctr;
                        while (byte(elemcborlen).length > ctr - lctr) {
                            res[ctr] = byte(elemcborlen)[ctr - lctr];
                            ctr++;
                        }
                    }
                    res[ctr] = elemArray[i][x];
                    ctr++;
                }
                res[ctr] = 0xFF;
                ctr++;
            }
            return res;
        }


    string oraclize_network_name;
    function oraclize_setNetworkName(string _network_name) internal {
        oraclize_network_name = _network_name;
    }

    function oraclize_getNetworkName() internal returns (string) {
        return oraclize_network_name;
    }

    function oraclize_newRandomDSQuery(uint _delay, uint _nbytes, uint _customGasLimit) internal returns (bytes32){
        if ((_nbytes == 0)||(_nbytes > 32)) throw;
        bytes memory nbytes = new bytes(1);
        nbytes[0] = byte(_nbytes);
        bytes memory unonce = new bytes(32);
        bytes memory sessionKeyHash = new bytes(32);
        bytes32 sessionKeyHash_bytes32 = oraclize_randomDS_getSessionPubKeyHash();
        assembly {
            mstore(unonce, 0x20)
            mstore(add(unonce, 0x20), xor(blockhash(sub(number, 1)), xor(coinbase, timestamp)))
            mstore(sessionKeyHash, 0x20)
            mstore(add(sessionKeyHash, 0x20), sessionKeyHash_bytes32)
        }
        bytes[3] memory args = [unonce, nbytes, sessionKeyHash];
        bytes32 queryId = oraclize_query(_delay, "random", args, _customGasLimit);
        oraclize_randomDS_setCommitment(queryId, sha3(bytes8(_delay), args[1], sha256(args[0]), args[2]));
        return queryId;
    }

    function oraclize_randomDS_setCommitment(bytes32 queryId, bytes32 commitment) internal {
        oraclize_randomDS_args[queryId] = commitment;
    }

    mapping(bytes32=>bytes32) oraclize_randomDS_args;
    mapping(bytes32=>bool) oraclize_randomDS_sessionKeysHashVerified;

    function verifySig(bytes32 tosignh, bytes dersig, bytes pubkey) internal returns (bool){
        bool sigok;
        address signer;

        bytes32 sigr;
        bytes32 sigs;

        bytes memory sigr_ = new bytes(32);
        uint offset = 4+(uint(dersig[3]) - 0x20);
        sigr_ = copyBytes(dersig, offset, 32, sigr_, 0);
        bytes memory sigs_ = new bytes(32);
        offset += 32 + 2;
        sigs_ = copyBytes(dersig, offset+(uint(dersig[offset-1]) - 0x20), 32, sigs_, 0);

        assembly {
            sigr := mload(add(sigr_, 32))
            sigs := mload(add(sigs_, 32))
        }


        (sigok, signer) = safer_ecrecover(tosignh, 27, sigr, sigs);
        if (address(sha3(pubkey)) == signer) return true;
        else {
            (sigok, signer) = safer_ecrecover(tosignh, 28, sigr, sigs);
            return (address(sha3(pubkey)) == signer);
        }
    }

    function oraclize_randomDS_proofVerify__sessionKeyValidity(bytes proof, uint sig2offset) internal returns (bool) {
        bool sigok;

        // Step 6: verify the attestation signature, APPKEY1 must sign the sessionKey from the correct ledger app (CODEHASH)
        bytes memory sig2 = new bytes(uint(proof[sig2offset+1])+2);
        copyBytes(proof, sig2offset, sig2.length, sig2, 0);

        bytes memory appkey1_pubkey = new bytes(64);
        copyBytes(proof, 3+1, 64, appkey1_pubkey, 0);

        bytes memory tosign2 = new bytes(1+65+32);
        tosign2[0] = 1; //role
        copyBytes(proof, sig2offset-65, 65, tosign2, 1);
        bytes memory CODEHASH = hex"fd94fa71bc0ba10d39d464d0d8f465efeef0a2764e3887fcc9df41ded20f505c";
        copyBytes(CODEHASH, 0, 32, tosign2, 1+65);
        sigok = verifySig(sha256(tosign2), sig2, appkey1_pubkey);

        if (sigok == false) return false;


        // Step 7: verify the APPKEY1 provenance (must be signed by Ledger)
        bytes memory LEDGERKEY = hex"7fb956469c5c9b89840d55b43537e66a98dd4811ea0a27224272c2e5622911e8537a2f8e86a46baec82864e98dd01e9ccc2f8bc5dfc9cbe5a91a290498dd96e4";

        bytes memory tosign3 = new bytes(1+65);
        tosign3[0] = 0xFE;
        copyBytes(proof, 3, 65, tosign3, 1);

        bytes memory sig3 = new bytes(uint(proof[3+65+1])+2);
        copyBytes(proof, 3+65, sig3.length, sig3, 0);

        sigok = verifySig(sha256(tosign3), sig3, LEDGERKEY);

        return sigok;
    }

    modifier oraclize_randomDS_proofVerify(bytes32 _queryId, string _result, bytes _proof) {
        // Step 1: the prefix has to match 'LP\x01' (Ledger Proof version 1)
        if ((_proof[0] != "L")||(_proof[1] != "P")||(_proof[2] != 1)) throw;

        bool proofVerified = oraclize_randomDS_proofVerify__main(_proof, _queryId, bytes(_result), oraclize_getNetworkName());
        if (proofVerified == false) throw;

        _;
    }

    function oraclize_randomDS_proofVerify__returnCode(bytes32 _queryId, string _result, bytes _proof) internal returns (uint8){
        // Step 1: the prefix has to match 'LP\x01' (Ledger Proof version 1)
        if ((_proof[0] != "L")||(_proof[1] != "P")||(_proof[2] != 1)) return 1;

        bool proofVerified = oraclize_randomDS_proofVerify__main(_proof, _queryId, bytes(_result), oraclize_getNetworkName());
        if (proofVerified == false) return 2;

        return 0;
    }

    function matchBytes32Prefix(bytes32 content, bytes prefix, uint n_random_bytes) internal returns (bool){
        bool match_ = true;
        
        for (uint256 i=0; i< n_random_bytes; i++) {
            if (content[i] != prefix[i]) match_ = false;
        }

        return match_;
    }

    function oraclize_randomDS_proofVerify__main(bytes proof, bytes32 queryId, bytes result, string context_name) internal returns (bool){

        // Step 2: the unique keyhash has to match with the sha256 of (context name + queryId)
        uint ledgerProofLength = 3+65+(uint(proof[3+65+1])+2)+32;
        bytes memory keyhash = new bytes(32);
        copyBytes(proof, ledgerProofLength, 32, keyhash, 0);
        if (!(sha3(keyhash) == sha3(sha256(context_name, queryId)))) return false;

        bytes memory sig1 = new bytes(uint(proof[ledgerProofLength+(32+8+1+32)+1])+2);
        copyBytes(proof, ledgerProofLength+(32+8+1+32), sig1.length, sig1, 0);

        // Step 3: we assume sig1 is valid (it will be verified during step 5) and we verify if 'result' is the prefix of sha256(sig1)
        if (!matchBytes32Prefix(sha256(sig1), result, uint(proof[ledgerProofLength+32+8]))) return false;

        // Step 4: commitment match verification, sha3(delay, nbytes, unonce, sessionKeyHash) == commitment in storage.
        // This is to verify that the computed args match with the ones specified in the query.
        bytes memory commitmentSlice1 = new bytes(8+1+32);
        copyBytes(proof, ledgerProofLength+32, 8+1+32, commitmentSlice1, 0);

        bytes memory sessionPubkey = new bytes(64);
        uint sig2offset = ledgerProofLength+32+(8+1+32)+sig1.length+65;
        copyBytes(proof, sig2offset-64, 64, sessionPubkey, 0);

        bytes32 sessionPubkeyHash = sha256(sessionPubkey);
        if (oraclize_randomDS_args[queryId] == sha3(commitmentSlice1, sessionPubkeyHash)){ //unonce, nbytes and sessionKeyHash match
            delete oraclize_randomDS_args[queryId];
        } else return false;


        // Step 5: validity verification for sig1 (keyhash and args signed with the sessionKey)
        bytes memory tosign1 = new bytes(32+8+1+32);
        copyBytes(proof, ledgerProofLength, 32+8+1+32, tosign1, 0);
        if (!verifySig(sha256(tosign1), sig1, sessionPubkey)) return false;

        // verify if sessionPubkeyHash was verified already, if not.. let's do it!
        if (oraclize_randomDS_sessionKeysHashVerified[sessionPubkeyHash] == false){
            oraclize_randomDS_sessionKeysHashVerified[sessionPubkeyHash] = oraclize_randomDS_proofVerify__sessionKeyValidity(proof, sig2offset);
        }

        return oraclize_randomDS_sessionKeysHashVerified[sessionPubkeyHash];
    }


    // the following function has been written by Alex Beregszaszi (@axic), use it under the terms of the MIT license
    function copyBytes(bytes from, uint fromOffset, uint length, bytes to, uint toOffset) internal returns (bytes) {
        uint minLength = length + toOffset;

        if (to.length < minLength) {
            // Buffer too small
            throw; // Should be a better way?
        }

        // NOTE: the offset 32 is added to skip the `size` field of both bytes variables
        uint i = 32 + fromOffset;
        uint j = 32 + toOffset;

        while (i < (32 + fromOffset + length)) {
            assembly {
                let tmp := mload(add(from, i))
                mstore(add(to, j), tmp)
            }
            i += 32;
            j += 32;
        }

        return to;
    }

    // the following function has been written by Alex Beregszaszi (@axic), use it under the terms of the MIT license
    // Duplicate Solidity's ecrecover, but catching the CALL return value
    function safer_ecrecover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal returns (bool, address) {
        // We do our own memory management here. Solidity uses memory offset
        // 0x40 to store the current end of memory. We write past it (as
        // writes are memory extensions), but don't update the offset so
        // Solidity will reuse it. The memory used here is only needed for
        // this context.

        // FIXME: inline assembly can't access return values
        bool ret;
        address addr;

        assembly {
            let size := mload(0x40)
            mstore(size, hash)
            mstore(add(size, 32), v)
            mstore(add(size, 64), r)
            mstore(add(size, 96), s)

            // NOTE: we can reuse the request memory because we deal with
            //       the return code
            ret := call(3000, 1, 0, size, 128, size, 32)
            addr := mload(size)
        }

        return (ret, addr);
    }

    // the following function has been written by Alex Beregszaszi (@axic), use it under the terms of the MIT license
    function ecrecovery(bytes32 hash, bytes sig) internal returns (bool, address) {
        bytes32 r;
        bytes32 s;
        uint8 v;

        if (sig.length != 65)
          return (false, 0);

        // The signature format is a compact form of:
        //   {bytes32 r}{bytes32 s}{uint8 v}
        // Compact means, uint8 is not padded to 32 bytes.
        assembly {
            r := mload(add(sig, 32))
            s := mload(add(sig, 64))

            // Here we are loading the last 32 bytes. We exploit the fact that
            // 'mload' will pad with zeroes if we overread.
            // There is no 'mload8' to do this, but that would be nicer.
            v := byte(0, mload(add(sig, 96)))

            // Alternative solution:
            // 'byte' is not working due to the Solidity parser, so lets
            // use the second best option, 'and'
            // v := and(mload(add(sig, 65)), 255)
        }

        // albeit non-transactional signatures are not specified by the YP, one would expect it
        // to match the YP range of [27, 28]
        //
        // geth uses [0, 1] and some clients have followed. This might change, see:
        //  https://github.com/ethereum/go-ethereum/issues/2053
        if (v < 27)
          v += 27;

        if (v != 27 && v != 28)
            return (false, 0);

        return safer_ecrecover(hash, v, r, s);
    }

}
// </ORACLIZE_API>


//import "github.com/OpenZeppelin/zeppelin-solidity/contracts/math/SafeMath.sol";



/**
 * @title SafeMath
 * @dev Math operations with safety checks that throw on error
 */
library SafeMath {
  function mul(uint256 a, uint256 b) internal pure returns (uint256) {
    if (a == 0) {
      return 0;
    }
    uint256 c = a * b;
    assert(c / a == b);
    return c;
  }

  function div(uint256 a, uint256 b) internal pure returns (uint256) {
    // assert(b > 0); // Solidity automatically throws when dividing by 0
    uint256 c = a / b;
    // assert(a == b * c + a % b); // There is no case in which this doesn't hold
    return c;
  }

  function sub(uint256 a, uint256 b) internal pure returns (uint256) {
    assert(b <= a);
    return a - b;
  }

  function add(uint256 a, uint256 b) internal pure returns (uint256) {
    uint256 c = a + b;
    assert(c >= a);
    return c;
  }
}



//import "github.com/OpenZeppelin/zeppelin-solidity/contracts/ownership/Ownable.sol";


//import "github.com/OpenZeppelin/zeppelin-solidity/contracts/token/BurnableToken.sol";







//import '../math/SafeMath.sol';



/**
 * @title Basic token
 * @dev Basic version of StandardToken, with no allowances.
 */
contract BasicToken is ERC20Basic {
  using SafeMath for uint256;

  mapping(address => uint256) balances;

  /**
  * @dev transfer token for a specified address
  * @param _to The address to transfer to.
  * @param _value The amount to be transferred.
  */
  function transfer(address _to, uint256 _value) public returns (bool) {
    require(_to != address(0));
    require(_value <= balances[msg.sender]);

    // SafeMath.sub will throw if there is not enough balance.
    balances[msg.sender] = balances[msg.sender].sub(_value);
    balances[_to] = balances[_to].add(_value);
    Transfer(msg.sender, _to, _value);
    return true;
  }

  /**
  * @dev Gets the balance of the specified address.
  * @param _owner The address to query the the balance of.
  * @return An uint256 representing the amount owned by the passed address.
  */
  function balanceOf(address _owner) public view returns (uint256 balance) {
    return balances[_owner];
  }

}


/**
 * @title Burnable Token
 * @dev Token that can be irreversibly burned (destroyed).
 */
contract BurnableToken is BasicToken {

    event Burn(address indexed burner, uint256 value);

    /**
     * @dev Burns a specific amount of tokens.
     * @param _value The amount of token to be burned.
     */
    function burn(uint256 _value) public {
        require(_value <= balances[msg.sender]);
        // no need to require value <= totalSupply, since that would imply the
        // sender's balance is greater than the totalSupply, which *should* be an assertion failure

        address burner = msg.sender;
        balances[burner] = balances[burner].sub(_value);
        totalSupply = totalSupply.sub(_value);
        Burn(burner, _value);
    }
}




 /* ERC223 additions to ERC20 */



 /*
  ERC223 additions to ERC20

  Interface wise is ERC20 + data paramenter to transfer and transferFrom.
 */

//import "github.com/OpenZeppelin/zeppelin-solidity/contracts/token/ERC20.sol";






/**
 * @title ERC20 interface
 * @dev see https://github.com/ethereum/EIPs/issues/20
 */
contract ERC20 is ERC20Basic {
  function allowance(address owner, address spender) public view returns (uint256);
  function transferFrom(address from, address to, uint256 value) public returns (bool);
  function approve(address spender, uint256 value) public returns (bool);
  event Approval(address indexed owner, address indexed spender, uint256 value);
}


contract ERC223 is ERC20 {
  function transfer(address to, uint value, bytes data) returns (bool ok);
  function transferFrom(address from, address to, uint value, bytes data) returns (bool ok);
  
  event Transfer(address indexed from, address indexed to, uint value, bytes indexed data);
}



/*
Base class contracts willing to accept ERC223 token transfers must conform to.

Sender: msg.sender to the token contract, the address originating the token transfer.
          - For user originated transfers sender will be equal to tx.origin
          - For contract originated transfers, tx.origin will be the user that made the tx that produced the transfer.
Origin: the origin address from whose balance the tokens are sent
          - For transfer(), origin = msg.sender
          - For transferFrom() origin = _from to token contract
Value is the amount of tokens sent
Data is arbitrary data sent with the token transfer. Simulates ether tx.data

From, origin and value shouldn't be trusted unless the token contract is trusted.
If sender == tx.origin, it is safe to trust it regardless of the token.
*/

contract ERC223Receiver {
  function tokenFallback(address _from, uint _value, bytes _data);
}


//import "github.com/OpenZeppelin/zeppelin-solidity/contracts/token/StandardToken.sol";







/**
 * @title Standard ERC20 token
 *
 * @dev Implementation of the basic standard token.
 * @dev https://github.com/ethereum/EIPs/issues/20
 * @dev Based on code by FirstBlood: https://github.com/Firstbloodio/token/blob/master/smart_contract/FirstBloodToken.sol
 */
contract StandardToken is ERC20, BasicToken {

  mapping (address => mapping (address => uint256)) internal allowed;


  /**
   * @dev Transfer tokens from one address to another
   * @param _from address The address which you want to send tokens from
   * @param _to address The address which you want to transfer to
   * @param _value uint256 the amount of tokens to be transferred
   */
  function transferFrom(address _from, address _to, uint256 _value) public returns (bool) {
    require(_to != address(0));
    require(_value <= balances[_from]);
    require(_value <= allowed[_from][msg.sender]);

    balances[_from] = balances[_from].sub(_value);
    balances[_to] = balances[_to].add(_value);
    allowed[_from][msg.sender] = allowed[_from][msg.sender].sub(_value);
    Transfer(_from, _to, _value);
    return true;
  }

  /**
   * @dev Approve the passed address to spend the specified amount of tokens on behalf of msg.sender.
   *
   * Beware that changing an allowance with this method brings the risk that someone may use both the old
   * and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this
   * race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards:
   * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
   * @param _spender The address which will spend the funds.
   * @param _value The amount of tokens to be spent.
   */
  function approve(address _spender, uint256 _value) public returns (bool) {
    allowed[msg.sender][_spender] = _value;
    Approval(msg.sender, _spender, _value);
    return true;
  }

  /**
   * @dev Function to check the amount of tokens that an owner allowed to a spender.
   * @param _owner address The address which owns the funds.
   * @param _spender address The address which will spend the funds.
   * @return A uint256 specifying the amount of tokens still available for the spender.
   */
  function allowance(address _owner, address _spender) public view returns (uint256) {
    return allowed[_owner][_spender];
  }

  /**
   * @dev Increase the amount of tokens that an owner allowed to a spender.
   *
   * approve should be called when allowed[_spender] == 0. To increment
   * allowed value is better to use this function to avoid 2 calls (and wait until
   * the first transaction is mined)
   * From MonolithDAO Token.sol
   * @param _spender The address which will spend the funds.
   * @param _addedValue The amount of tokens to increase the allowance by.
   */
  function increaseApproval(address _spender, uint _addedValue) public returns (bool) {
    allowed[msg.sender][_spender] = allowed[msg.sender][_spender].add(_addedValue);
    Approval(msg.sender, _spender, allowed[msg.sender][_spender]);
    return true;
  }

  /**
   * @dev Decrease the amount of tokens that an owner allowed to a spender.
   *
   * approve should be called when allowed[_spender] == 0. To decrement
   * allowed value is better to use this function to avoid 2 calls (and wait until
   * the first transaction is mined)
   * From MonolithDAO Token.sol
   * @param _spender The address which will spend the funds.
   * @param _subtractedValue The amount of tokens to decrease the allowance by.
   */
  function decreaseApproval(address _spender, uint _subtractedValue) public returns (bool) {
    uint oldValue = allowed[msg.sender][_spender];
    if (_subtractedValue > oldValue) {
      allowed[msg.sender][_spender] = 0;
    } else {
      allowed[msg.sender][_spender] = oldValue.sub(_subtractedValue);
    }
    Approval(msg.sender, _spender, allowed[msg.sender][_spender]);
    return true;
  }

}


contract Standard223Token is ERC223, StandardToken {
  //function that is called when a user or another contract wants to transfer funds
  function transfer(address _to, uint _value, bytes _data) returns (bool success) {
    //filtering if the target is a contract with bytecode inside it
    if (!super.transfer(_to, _value)) throw; // do a normal token transfer
    if (isContract(_to)) contractFallback(msg.sender, _to, _value, _data);
   Transfer(msg.sender, _to, _value, _data);
    return true;
  }

  function transferFrom(address _from, address _to, uint _value, bytes _data) returns (bool success) {
    if (!super.transferFrom(_from, _to, _value)) throw; // do a normal token transfer
    if (isContract(_to)) contractFallback(_from, _to, _value, _data);
    Transfer(_from, _to, _value, _data);
    return true;
  }

  function transfer(address _to, uint _value) returns (bool success) {
    return transfer(_to, _value, new bytes(0));
  }

  function transferFrom(address _from, address _to, uint _value) returns (bool success) {
    return transferFrom(_from, _to, _value, new bytes(0));
  }

  //function that is called when transaction target is a contract
  function contractFallback(address _origin, address _to, uint _value, bytes _data) private {
    ERC223Receiver reciever = ERC223Receiver(_to);
    reciever.tokenFallback(_origin, _value, _data);
  }

  //assemble the given address bytecode. If bytecode exists then the _addr is a contract.
  function isContract(address _addr) private returns (bool is_contract) {
    // retrieve the size of the code on target address, this needs assembly
    uint length;
    assembly { length := extcodesize(_addr) }
    return length > 0;
  }
}






/**
 * @title RefundVault
 * @dev This contract is used for storing funds while a crowdsale
 * is in progress. Supports refunding the money if crowdsale fails,
 * and forwarding it if crowdsale is successful.
 */
contract RefundVault {
  using SafeMath for uint256;

  enum State { Active, Refunding, Released}

  mapping (address => uint256) public vault_deposited;
  address public vault_wallet;
  State public vault_state;
  uint256 totalDeposited = 0;
  uint256 public refundDeadline;

  event DepositReleased();
  event RefundsEnabled();
  event RefundsDisabled();
  event Refunded(address indexed beneficiary, uint256 weiAmount);

  function RefundVault() public {
    vault_state = State.Active;
  }

  function vault_deposit(address investor, uint256 _value) internal {
    require(vault_state == State.Active);
    vault_deposited[investor] = vault_deposited[investor].add(_value);
    totalDeposited = totalDeposited.add(_value);
  }

  function vault_releaseDeposit() internal {
    vault_state = State.Released;
    DepositReleased();
    if (totalDeposited > 0) {vault_wallet.transfer(totalDeposited);}
    totalDeposited = 0;
  }

  function vault_enableRefunds() internal {
    require(vault_state == State.Active);
    refundDeadline = now + 180 days;
    vault_state = State.Refunding;
    RefundsEnabled();
  }

  function vault_refund(address investor) internal {
    require(vault_state == State.Refunding);
    uint256 depositedValue = vault_deposited[investor];
    vault_deposited[investor] = 0;
    investor.transfer(depositedValue);
    Refunded(investor, depositedValue);
    totalDeposited = totalDeposited.sub(depositedValue);
  }
}



contract DGTX is usingOraclize, Ownable, RefundVault, BurnableToken, Standard223Token
{
    string public constant name = "DigitexFutures";
    string public constant symbol = "DGTX";
    uint8 public constant decimals = 18;
    uint public constant DECIMALS_MULTIPLIER = 10**uint(decimals);
    
    uint public ICOstarttime = 1516024800;           //2018.1.15  January 15, 2018 2:00:00 PM GMT 1516024800
    uint public ICOendtime = 1518757200;             //2018.2.15 February 16, 2018 5:00:00 AM GMT 1518757200
    
    uint public minimumInvestmentInWei = DECIMALS_MULTIPLIER / 100;
    uint public maximumInvestmentInWei = 1000 * 1 ether;
    address saleWalletAddress;

    uint256 public constant softcapInTokens = 25000000 * DECIMALS_MULTIPLIER; //25000000 * DECIMALS_MULTIPLIER;
    uint256 public constant hardcapInTokens = 650000000 * DECIMALS_MULTIPLIER;
    
    uint256 public totaltokensold = 0;
    
    uint public USDETH = 1205;
    uint NumberOfTokensIn1USD = 100;
    
    //RefundVault public vault;
    bool public isFinalized = false;
    event Finalized();
    
    event newOraclizeQuery(string description);
    event newETHUSDPrice(string price);
    
    function increaseSupply(uint value, address to) public onlyOwner returns (bool) {
        totalSupply = totalSupply.add(value);
        balances[to] = balances[to].add(value);
        Transfer(0, to, value);
        return true;
    }
    
    /*function decreaseSupply(uint value, address from) public onlyOwner returns (bool) {
        balances[from] = balances[from].sub(value);
        totalSupply = totalSupply.sub(value);
        Transfer(from, 0, value);
        return true;
    }*/

    
    
    function burn(uint256 _value) public {
        require(0 != _value);
        
        super.burn(_value);
        Transfer(msg.sender, 0, _value);
    }
    
    /*function StartNextCampain(uint _ICOstarttime, uint _ICOendtime, uint _minimumInvestment, uint _maximumInvestment, uint _NumberOfTokensIn1USD) public onlyOwner {
        require(!ICOactive());
        require(State.Released == vault_state);
        
        ICOstarttime = _ICOstarttime;
        ICOendtime = _ICOendtime;
        minimumInvestmentInWei = _minimumInvestment;
        maximumInvestmentInWei = _maximumInvestment;
        NumberOfTokensIn1USD = _NumberOfTokensIn1USD;
        UpdateUSDETHPriceAfter(0);
    }*/

    
    function transferOwnership(address newOwner) public onlyOwner {
        require(newOwner != address(0));
        uint256 localOwnerBalance = balances[owner];
        balances[newOwner] = balances[newOwner].add(localOwnerBalance);
        balances[owner] = 0;
        vault_wallet = newOwner;
        Transfer(owner, newOwner, localOwnerBalance);
        super.transferOwnership(newOwner);
    }
    
    function finalize() public {
        require(!isFinalized);
        require(ICOendtime < now);
        finalization();
        Finalized();
        isFinalized = true;
    }
  
    function depositFunds() internal {
        vault_deposit(msg.sender, msg.value * 96 / 100);
    }
    
    // if crowdsale is unsuccessful, investors can claim refunds here
    function claimRefund() public {
        require(isFinalized);
        require(!goalReached());
        
        uint256 refundedTokens = balances[msg.sender];
        balances[owner] = balances[owner].add(refundedTokens);
        totaltokensold = totaltokensold.sub(refundedTokens);
        balances[msg.sender] = 0;
        
        Transfer(msg.sender, owner, refundedTokens);
        
        vault_refund(msg.sender);
    }
    
    // vault finalization task, called when owner calls finalize()
    function finalization() internal {
        if (goalReached()) {
            vault_releaseDeposit();
        } else {
            vault_enableRefunds();
            
        }
    }
    
    function releaseUnclaimedFunds() onlyOwner public {
        require(vault_state == State.Refunding && now >= refundDeadline);
        vault_releaseDeposit();
    }

    function goalReached() public view returns (bool) {
        return totaltokensold >= softcapInTokens;
    }    
    
    function __callback(bytes32 myid, string result) {
        require (msg.sender == oraclize_cbAddress());

        newETHUSDPrice(result);

        USDETH = parseInt(result, 0);
        if ((now < ICOendtime) && (totaltokensold < hardcapInTokens))
        {
            UpdateUSDETHPriceAfter(day); //update every 24 hours
        }
        
    }
    

  function UpdateUSDETHPriceAfter (uint delay) private {
      
    newOraclizeQuery("Update of USD/ETH price requested");
    oraclize_query(delay, "URL", "json(https://api.etherscan.io/api?module=stats&action=ethprice&apikey=YourApiKeyToken).result.ethusd");
       
  }


  

  function DGTX() public payable {
      totalSupply = 1000000000 * DECIMALS_MULTIPLIER;
      balances[owner] = totalSupply;
      vault_wallet = owner;
      Transfer(0x0, owner, totalSupply);
      initializeSaleWalletAddress();
      UpdateUSDETHPriceAfter(0);
  }
  
  function initializeSaleWalletAddress() private {
      saleWalletAddress = 0xd8A56FB51B86e668B5665E83E0a31E3696578333;
      
  }
  

  /*function  SendEther ( uint _amount) onlyOwner public {
      require(this.balance > _amount);
      owner.transfer(_amount);
  } */

  

  function () payable {
       if (msg.sender != owner) {
          buy();
       }
  }
  
  function ICOactive() public view returns (bool success) {
      if (ICOstarttime < now && now < ICOendtime && totaltokensold < hardcapInTokens) {
          return true;
      }
      
      return false;
  }

  function buy() payable {

      

      require (msg.value >= minimumInvestmentInWei && msg.value <= maximumInvestmentInWei);

      require (ICOactive());
      
      uint256 NumberOfTokensToGive = msg.value.mul(USDETH).mul(NumberOfTokensIn1USD);
     

      
      if(now <= ICOstarttime + week) {
          
          NumberOfTokensToGive = NumberOfTokensToGive.mul(120).div(100);
          
      } else if(now <= ICOstarttime + 2*week){
          
          NumberOfTokensToGive = NumberOfTokensToGive.mul(115).div(100);
          
      } else if(now <= ICOstarttime + 3*week){
          
          NumberOfTokensToGive = NumberOfTokensToGive.mul(110).div(100);
          
      } else{
          NumberOfTokensToGive = NumberOfTokensToGive.mul(105).div(100);
      }
      
      uint256 localTotaltokensold = totaltokensold;
      require(localTotaltokensold + NumberOfTokensToGive <= hardcapInTokens);
      totaltokensold = localTotaltokensold.add(NumberOfTokensToGive);
      
      address localOwner = owner;
      balances[msg.sender] = balances[msg.sender].add(NumberOfTokensToGive);
      balances[localOwner] = balances[localOwner].sub(NumberOfTokensToGive);
      Transfer(localOwner, msg.sender, NumberOfTokensToGive);
      
      saleWalletAddress.transfer(msg.value - msg.value * 96 / 100);
      
      if(!goalReached() && (RefundVault.State.Active == vault_state))
      {
          depositFunds();
      } else {
          if(RefundVault.State.Active == vault_state) {vault_releaseDeposit();}
          localOwner.transfer(msg.value * 96 / 100);
      }
  }
}

    Contract ABI  
[{"constant":true,"inputs":[],"name":"name","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_value","type":"uint256"}],"name":"approve","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"value","type":"uint256"},{"name":"to","type":"address"}],"name":"increaseSupply","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"totalSupply","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"softcapInTokens","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"releaseUnclaimedFunds","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_from","type":"address"},{"name":"_to","type":"address"},{"name":"_value","type":"uint256"}],"name":"transferFrom","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"myid","type":"bytes32"},{"name":"result","type":"string"}],"name":"__callback","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"decimals","outputs":[{"name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"myid","type":"bytes32"},{"name":"result","type":"string"},{"name":"proof","type":"bytes"}],"name":"__callback","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"USDETH","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_value","type":"uint256"}],"name":"burn","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"maximumInvestmentInWei","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"finalize","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"ICOactive","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"ICOstarttime","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_subtractedValue","type":"uint256"}],"name":"decreaseApproval","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_owner","type":"address"}],"name":"balanceOf","outputs":[{"name":"balance","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"goalReached","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"isFinalized","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"symbol","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"vault_state","outputs":[{"name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"buy","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[],"name":"totaltokensold","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_to","type":"address"},{"name":"_value","type":"uint256"}],"name":"transfer","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_from","type":"address"},{"name":"_to","type":"address"},{"name":"_value","type":"uint256"},{"name":"_data","type":"bytes"}],"name":"transferFrom","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"hardcapInTokens","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"claimRefund","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"DECIMALS_MULTIPLIER","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_to","type":"address"},{"name":"_value","type":"uint256"},{"name":"_data","type":"bytes"}],"name":"transfer","outputs":[{"name":"success","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"vault_deposited","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_spender","type":"address"},{"name":"_addedValue","type":"uint256"}],"name":"increaseApproval","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_owner","type":"address"},{"name":"_spender","type":"address"}],"name":"allowance","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"refundDeadline","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"vault_wallet","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"ICOendtime","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"minimumInvestmentInWei","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[],"payable":true,"stateMutability":"payable","type":"constructor"},{"payable":true,"stateMutability":"payable","type":"fallback"},{"anonymous":false,"inputs":[],"name":"Finalized","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"description","type":"string"}],"name":"newOraclizeQuery","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"price","type":"string"}],"name":"newETHUSDPrice","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"burner","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Burn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"to","type":"address"},{"indexed":false,"name":"value","type":"uint256"},{"indexed":true,"name":"data","type":"bytes"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"owner","type":"address"},{"indexed":true,"name":"spender","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"to","type":"address"},{"indexed":false,"name":"value","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[],"name":"DepositReleased","type":"event"},{"anonymous":false,"inputs":[],"name":"RefundsEnabled","type":"event"},{"anonymous":false,"inputs":[],"name":"RefundsDisabled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"beneficiary","type":"address"},{"indexed":false,"name":"weiAmount","type":"uint256"}],"name":"Refunded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"previousOwner","type":"address"},{"indexed":true,"name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"}]

  Contract Creation Code Switch To Opcodes View
6060604090815260006008819055635a5cb3e0600d55635a866550600e55662386f26fc10000600f55683635c9adc5dea0000060105560128190556104b560135560646014556015805460ff1916905560058054600160a060020a03338116600160a060020a0319928316178084556007805460a060020a60ff02191681556b033b2e3c9fd0803ce8000000600a8190559183168652600b60205286862082905593548454921691909216811790925590927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef91905190815260200160405180910390a3620000fb640100000000620028326200011b82021704565b620001156000640100000000620018ee6200014382021704565b62000b76565b60118054600160a060020a03191673d8a56fb51b86e668b5665e83e0a31e3696578333179055565b7f46cb989ef9cef13e930e3b7f286225a086e716a90d63e0b7da85d310a9db0c9a60405160208082526021908201527f557064617465206f66205553442f4554482070726963652072657175657374656040808301919091527f640000000000000000000000000000000000000000000000000000000000000060608301526080909101905180910390a1620002c5816040805190810160405280600381526020017f55524c000000000000000000000000000000000000000000000000000000000081525060a06040519081016040908152606482527f6a736f6e2868747470733a2f2f6170692e65746865727363616e2e696f2f617060208301527f693f6d6f64756c653d737461747326616374696f6e3d65746870726963652661908201527f70696b65793d596f75724170694b6579546f6b656e292e726573756c742e657460608201527f687573640000000000000000000000000000000000000000000000000000000060808201526401000000006200237d620002c982021704565b5050565b600080548190600160a060020a031615806200030757506000546200030590600160a060020a031664010000000062002053620006dc82021704565b155b15620003295762000327600064010000000062002057620006e082021704565b505b60008054600160a060020a0316906338cc483190604051602001526040518163ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401602060405180830381600087803b15156200038c57600080fd5b6102c65a03f115156200039e57600080fd5b5050506040518051600154600160a060020a0390811691161490506200045d5760008054600160a060020a0316906338cc483190604051602001526040518163ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401602060405180830381600087803b15156200042157600080fd5b6102c65a03f115156200043357600080fd5b505050604051805160018054600160a060020a031916600160a060020a0392909216919091179055505b600154600160a060020a031663524f3889856000604051602001526040518263ffffffff167c01000000000000000000000000000000000000000000000000000000000281526004018080602001828103825283818151815260200191508051906020019080838360005b83811015620004e2578082015183820152602001620004c8565b50505050905090810190601f168015620005105780820380516001836020036101000a031916815260200191505b5092505050602060405180830381600087803b15156200052f57600080fd5b6102c65a03f115156200054157600080fd5b5050506040518051915050670de0b6b3a764000062030d403a02018111156200056e5760009150620006d4565b600154600160a060020a031663adf59f99828787876000604051602001526040518563ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808481526020018060200180602001838103835285818151815260200191508051906020019080838360005b8381101562000600578082015183820152602001620005e6565b50505050905090810190601f1680156200062e5780820380516001836020036101000a031916815260200191505b50838103825284818151815260200191508051906020019080838360005b83811015620006665780820151838201526020016200064c565b50505050905090810190601f168015620006945780820380516001836020036101000a031916815260200191505b50955050505050506020604051808303818588803b1515620006b557600080fd5b6125ee5a03f11515620006c757600080fd5b5050505060405180519250505b509392505050565b3b90565b60008062000710731d3b2638a7cc9f2cb3d298a3da7a90b67e5506ed64010000000062002053620006dc82021704565b1115620007925760008054600160a060020a031916731d3b2638a7cc9f2cb3d298a3da7a90b67e5506ed1790556200078960408051908101604052600b81527f6574685f6d61696e6e657400000000000000000000000000000000000000000060208201526401000000006200277562000ac282021704565b50600162000abd565b6000620007c173c03a2615d5efaf5f49f60b7bb6583eaec212fdf164010000000062002053620006dc82021704565b11156200083a5760008054600160a060020a03191673c03a2615d5efaf5f49f60b7bb6583eaec212fdf11790556200078960408051908101604052600c81527f6574685f726f707374656e33000000000000000000000000000000000000000060208201526401000000006200277562000ac282021704565b60006200086973b7a07bcf2ba2f2703b24c0691b5278999c59ac7e64010000000062002053620006dc82021704565b1115620008e25760008054600160a060020a03191673b7a07bcf2ba2f2703b24c0691b5278999c59ac7e1790556200078960408051908101604052600981527f6574685f6b6f76616e000000000000000000000000000000000000000000000060208201526401000000006200277562000ac282021704565b60006200091173146500cfd35b22e4a392fe0adc06de1a1368ed4864010000000062002053620006dc82021704565b11156200098a5760008054600160a060020a03191673146500cfd35b22e4a392fe0adc06de1a1368ed481790556200078960408051908101604052600b81527f6574685f72696e6b65627900000000000000000000000000000000000000000060208201526401000000006200277562000ac282021704565b6000620009b9736f485c8bf6fc43ea212e93bbf8ce046c7f1cb47564010000000062002053620006dc82021704565b1115620009ef575060008054600160a060020a031916736f485c8bf6fc43ea212e93bbf8ce046c7f1cb475179055600162000abd565b600062000a1e7320e12a1f859b3feae5fb2a0a32c18f5a65555bbf64010000000062002053620006dc82021704565b111562000a54575060008054600160a060020a0319167320e12a1f859b3feae5fb2a0a32c18f5a65555bbf179055600162000abd565b600062000a837351efaf4c8b3c9afbd5ab9f4bbc82784ab6ef8faa64010000000062002053620006dc82021704565b111562000ab9575060008054600160a060020a0319167351efaf4c8b3c9afbd5ab9f4bbc82784ab6ef8faa179055600162000abd565b5060005b919050565b6002818051620002c5929160200190828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1062000b1457805160ff191683800117855562000b44565b8280016001018555821562000b44579182015b8281111562000b4457825182559160200191906001019062000b27565b5062000b5292915062000b56565b5090565b62000b7391905b8082111562000b52576000815560010162000b5d565b90565b6128a68062000b866000396000f3006060604052600436106101c95763ffffffff60e060020a60003504166306fdde0381146101e9578063095ea7b314610273578063124fc7e0146102a957806318160ddd146102cb5780631938a238146102f05780631e217bf81461030357806323b872dd1461031657806327dc297e1461033e578063313ce5671461039457806338bbfa50146103bd578063411d6e191461045557806342966c681461046857806344fc93611461047e5780634bb278f314610491578063587d6a20146104a457806364f1873b146104b757806366188463146104ca57806370a08231146104ec5780637d3d65221461050b5780638d4e40831461051e5780638da5cb5b1461053157806395d89b41146105605780639ee9dd5c14610573578063a6f2ae3a146105aa578063a75c981d146105b2578063a9059cbb146105c5578063ab67aa58146105e7578063b01f31c914610653578063b5545a3c14610666578063bbdd366a14610679578063be45fd621461068c578063c9cf2d4e146106f1578063d73dd62314610710578063dd62ed3e14610732578063e1aa1bcc14610757578063ea7553f01461076a578063eafac3391461077d578063f2fde38b14610790578063fe052bc6146107af575b60055433600160a060020a039081169116146101e7576101e76107c2565b005b34156101f457600080fd5b6101fc610a6f565b60405160208082528190810183818151815260200191508051906020019080838360005b83811015610238578082015183820152602001610220565b50505050905090810190601f1680156102655780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b341561027e57600080fd5b610295600160a060020a0360043516602435610aa6565b604051901515815260200160405180910390f35b34156102b457600080fd5b610295600435600160a060020a0360243516610b12565b34156102d657600080fd5b6102de610bb8565b60405190815260200160405180910390f35b34156102fb57600080fd5b6102de610bbe565b341561030e57600080fd5b6101e7610bcd565b341561032157600080fd5b610295600160a060020a0360043581169060243516604435610c26565b341561034957600080fd5b6101e7600480359060446024803590810190830135806020601f82018190048102016040519081016040528181529291906020840183838082843750949650610c5f95505050505050565b341561039f57600080fd5b6103a7610d60565b60405160ff909116815260200160405180910390f35b34156103c857600080fd5b6101e7600480359060446024803590810190830135806020601f8201819004810201604051908101604052818152929190602084018383808284378201915050505050509190803590602001908201803590602001908080601f016020809104026020016040519081016040528181529291906020840183838082843750949650610a6a95505050505050565b341561046057600080fd5b6102de610d65565b341561047357600080fd5b6101e7600435610d6b565b341561048957600080fd5b6102de610db0565b341561049c57600080fd5b6101e7610db6565b34156104af57600080fd5b610295610e18565b34156104c257600080fd5b6102de610e5a565b34156104d557600080fd5b610295600160a060020a0360043516602435610e60565b34156104f757600080fd5b6102de600160a060020a0360043516610f5c565b341561051657600080fd5b610295610f7b565b341561052957600080fd5b610295610f90565b341561053c57600080fd5b610544610f99565b604051600160a060020a03909116815260200160405180910390f35b341561056b57600080fd5b6101fc610fa8565b341561057e57600080fd5b610586610fdf565b6040518082600281111561059657fe5b60ff16815260200191505060405180910390f35b6101e76107c2565b34156105bd57600080fd5b6102de610fef565b34156105d057600080fd5b610295600160a060020a0360043516602435610ff5565b34156105f257600080fd5b610295600160a060020a036004803582169160248035909116916044359160849060643590810190830135806020601f8201819004810201604051908101604052818152929190602084018383808284375094965061102c95505050505050565b341561065e57600080fd5b6102de61110c565b341561067157600080fd5b6101e761111c565b341561068457600080fd5b6102de6111fc565b341561069757600080fd5b61029560048035600160a060020a03169060248035919060649060443590810190830135806020601f8201819004810201604051908101604052818152929190602084018383808284375094965061120895505050505050565b34156106fc57600080fd5b6102de600160a060020a03600435166112e6565b341561071b57600080fd5b610295600160a060020a03600435166024356112f8565b341561073d57600080fd5b6102de600160a060020a036004358116906024351661139c565b341561076257600080fd5b6102de6113c7565b341561077557600080fd5b6105446113cd565b341561078857600080fd5b6102de6113dc565b341561079b57600080fd5b6101e7600160a060020a03600435166113e2565b34156107ba57600080fd5b6102de6114bb565b6000806000600f5434101580156107db57506010543411155b15156107e657600080fd5b6107ee610e18565b15156107f957600080fd5b610820601454610814601354346114c190919063ffffffff16565b9063ffffffff6114c116565b600d5490935062093a8001421161085a57610853606461084785607863ffffffff6114c116565b9063ffffffff6114ec16565b92506108bb565b600d546212750001421161087e57610853606461084785607363ffffffff6114c116565b600d54621baf800142116108a257610853606461084785606e63ffffffff6114c116565b6108b8606461084785606963ffffffff6114c116565b92505b60125491506b0219aada9b14535aca00000083830111156108db57600080fd5b6108eb828463ffffffff61150316565b60125550600554600160a060020a033381166000908152600b60205260409020549116906109199084611503565b600160a060020a033381166000908152600b6020526040808220939093559083168152205461094e908463ffffffff61151216565b600160a060020a038083166000818152600b60205260409081902093909355339091169160008051602061285b8339815191529086905190815260200160405180910390a3601154600160a060020a03166108fc6064606034020434039081150290604051600060405180830381858888f1935050505015156109d057600080fd5b6109d8610f7b565b1580156109fa575060075460a060020a900460ff1660028111156109f857fe5b155b15610a0c57610a07611524565b610a6a565b60075460a060020a900460ff166002811115610a2457fe5b1515610a3257610a32611534565b600160a060020a0381166064346060020480156108fc0290604051600060405180830381858888f193505050501515610a6a57600080fd5b505050565b60408051908101604052600e81527f4469676974657846757475726573000000000000000000000000000000000000602082015281565b600160a060020a033381166000818152600c6020908152604080832094871680845294909152808220859055909291907f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9259085905190815260200160405180910390a350600192915050565b60055460009033600160a060020a03908116911614610b3057600080fd5b600a54610b43908463ffffffff61150316565b600a55600160a060020a0382166000908152600b6020526040902054610b6f908463ffffffff61150316565b600160a060020a0383166000818152600b602052604080822093909355909160008051602061285b8339815191529086905190815260200160405180910390a350600192915050565b600a5481565b6a14adf4b7320334b900000081565b60055433600160a060020a03908116911614610be857600080fd5b600160075460a060020a900460ff166002811115610c0257fe5b148015610c1157506009544210155b1515610c1c57600080fd5b610c24611534565b565b6000610c578484846000604051805910610c3d5750595b818152601f19601f8301168101602001604052905061102c565b949350505050565b610c676115e0565b600160a060020a031633600160a060020a0316141515610c8657600080fd5b7fb0882c4b7f3efb64e3e21d0451716cab830381610b23afa8df786d7f5ba723f38160405160208082528190810183818151815260200191508051906020019080838360005b83811015610ce4578082015183820152602001610ccc565b50505050905090810190601f168015610d115780820380516001836020036101000a031916815260200191505b509250505060405180910390a1610d29816000611780565b601355600e5442108015610d4b57506012546b0219aada9b14535aca00000090105b15610d5c57610d5c620151806118ee565b5050565b601281565b60135481565b801515610d7757600080fd5b610d8081611a61565b600033600160a060020a031660008051602061285b8339815191528360405190815260200160405180910390a350565b60105481565b60155460ff1615610dc657600080fd5b600e54429010610dd557600080fd5b610ddd611b1b565b7f6823b073d48d6e3a7d385eeb601452d680e74bb46afe3255a7d778f3a9b1768160405160405180910390a16015805460ff19166001179055565b600042600d54108015610e2c5750600e5442105b8015610e4657506012546b0219aada9b14535aca00000090105b15610e5357506001610e57565b5060005b90565b600d5481565b600160a060020a033381166000908152600c6020908152604080832093861683529290529081205480831115610ebd57600160a060020a033381166000908152600c60209081526040808320938816835292905290812055610ef4565b610ecd818463ffffffff61151216565b600160a060020a033381166000908152600c60209081526040808320938916835292905220555b600160a060020a033381166000818152600c602090815260408083209489168084529490915290819020547f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925915190815260200160405180910390a3600191505b5092915050565b600160a060020a0381166000908152600b60205260409020545b919050565b6012546a14adf4b7320334b900000090101590565b60155460ff1681565b600554600160a060020a031681565b60408051908101604052600481527f4447545800000000000000000000000000000000000000000000000000000000602082015281565b60075460a060020a900460ff1681565b60125481565b60006110258383600060405180591061100b5750595b818152601f19601f83011681016020016040529050611208565b9392505050565b6000611039858585611b3d565b151561104457600080fd5b61104d84611cad565b1561105e5761105e85858585611cb5565b816040518082805190602001908083835b6020831061108e5780518252601f19909201916020918201910161106f565b6001836020036101000a0380198251168184511617909252505050919091019250604091505051809103902084600160a060020a031686600160a060020a03167fe19260aff97b920c7df27010903aeb9c8d2be5d310a2c67824cf3f15396e4c168660405190815260200160405180910390a4506001949350505050565b6b0219aada9b14535aca00000081565b60155460009060ff16151561113057600080fd5b611138610f7b565b1561114257600080fd5b50600160a060020a033381166000908152600b6020526040808220546005549093168252902054611179908263ffffffff61150316565b600554600160a060020a03166000908152600b60205260409020556012546111a7908263ffffffff61151216565b601255600160a060020a033381166000818152600b6020526040808220919091556005549092169160008051602061285b8339815191529084905190815260200160405180910390a36111f933611d9d565b50565b670de0b6b3a764000081565b60006112148484611e63565b151561121f57600080fd5b61122884611cad565b156112395761123933858585611cb5565b816040518082805190602001908083835b602083106112695780518252601f19909201916020918201910161124a565b6001836020036101000a0380198251168184511617909252505050919091019250604091505051809103902084600160a060020a031633600160a060020a03167fe19260aff97b920c7df27010903aeb9c8d2be5d310a2c67824cf3f15396e4c168660405190815260200160405180910390a45060019392505050565b60066020526000908152604090205481565b600160a060020a033381166000908152600c60209081526040808320938616835292905290812054611330908363ffffffff61150316565b600160a060020a033381166000818152600c602090815260408083209489168084529490915290819020849055919290917f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92591905190815260200160405180910390a350600192915050565b600160a060020a039182166000908152600c6020908152604080832093909416825291909152205490565b60095481565b600754600160a060020a031681565b600e5481565b60055460009033600160a060020a0390811691161461140057600080fd5b600160a060020a038216151561141557600080fd5b50600554600160a060020a039081166000908152600b602052604080822054928416825290205461144c908263ffffffff61150316565b600160a060020a038084166000818152600b60205260408082209490945560058054841682528482209190915560078054600160a060020a0319168317905554909291169060008051602061285b8339815191529084905190815260200160405180910390a3610d5c82611f4c565b600f5481565b6000808315156114d45760009150610f55565b508282028284828115156114e457fe5b041461102557fe5b60008082848115156114fa57fe5b04949350505050565b60008282018381101561102557fe5b60008282111561151e57fe5b50900390565b610c243360646060340204611fda565b6007805474ff00000000000000000000000000000000000000001916740200000000000000000000000000000000000000001790557f02300cbb55fb5a102abe3b448abbaad77c9d6fb438f1c39942177651c5f70e4660405160405180910390a1600060085411156115d957600754600854600160a060020a039091169080156108fc0290604051600060405180830381858888f1935050505015156115d957600080fd5b6000600855565b60008054600160a060020a0316158061160b575060005461160990600160a060020a0316612053565b155b1561161c5761161a6000612057565b505b60008054600160a060020a0316906338cc483190604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b151561166557600080fd5b6102c65a03f1151561167657600080fd5b5050506040518051600154600160a060020a0390811691161490506117195760008054600160a060020a0316906338cc483190604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b15156116de57600080fd5b6102c65a03f115156116ef57600080fd5b505050604051805160018054600160a060020a031916600160a060020a0392909216919091179055505b600154600160a060020a031663c281d19e6000604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b151561176157600080fd5b6102c65a03f1151561177257600080fd5b505050604051805191505090565b600061178a612788565b5082600080805b83518110156118d1577f30000000000000000000000000000000000000000000000000000000000000008482815181106117c757fe5b016020015160f860020a900460f860020a02600160f860020a0319161015801561183857507f390000000000000000000000000000000000000000000000000000000000000084828151811061181957fe5b016020015160f860020a900460f860020a02600160f860020a03191611155b1561188e5781156118575785151561184f576118d1565b600019909501945b600a83029250603084828151811061186b57fe5b016020015160f860020a900460f860020a0260f860020a900403830192506118c9565b83818151811061189a57fe5b016020015160f860020a900460f860020a02600160f860020a031916602e60f860020a0214156118c957600191505b600101611791565b60008611156118e35785600a0a830292505b509095945050505050565b7f46cb989ef9cef13e930e3b7f286225a086e716a90d63e0b7da85d310a9db0c9a60405160208082526021908201527f557064617465206f66205553442f4554482070726963652072657175657374656040808301919091527f640000000000000000000000000000000000000000000000000000000000000060608301526080909101905180910390a1610d5c816040805190810160405280600381526020017f55524c000000000000000000000000000000000000000000000000000000000081525060a060405190810160405280606481526020017f6a736f6e2868747470733a2f2f6170692e65746865727363616e2e696f2f617081526020017f693f6d6f64756c653d737461747326616374696f6e3d6574687072696365266181526020017f70696b65793d596f75724170694b6579546f6b656e292e726573756c742e657481526020017f687573640000000000000000000000000000000000000000000000000000000081525061237d565b600160a060020a0333166000908152600b6020526040812054821115611a8657600080fd5b5033600160a060020a0381166000908152600b6020526040902054611aab9083611512565b600160a060020a0382166000908152600b6020526040902055600a54611ad7908363ffffffff61151216565b600a55600160a060020a0381167fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca58360405190815260200160405180910390a25050565b611b23610f7b565b15611b3557611b30611534565b610c24565b610c246126f6565b6000600160a060020a0383161515611b5457600080fd5b600160a060020a0384166000908152600b6020526040902054821115611b7957600080fd5b600160a060020a038085166000908152600c602090815260408083203390941683529290522054821115611bac57600080fd5b600160a060020a0384166000908152600b6020526040902054611bd5908363ffffffff61151216565b600160a060020a038086166000908152600b60205260408082209390935590851681522054611c0a908363ffffffff61150316565b600160a060020a038085166000908152600b60209081526040808320949094558783168252600c8152838220339093168252919091522054611c52908363ffffffff61151216565b600160a060020a038086166000818152600c60209081526040808320338616845290915290819020939093559085169160008051602061285b8339815191529085905190815260200160405180910390a35060019392505050565b6000903b1190565b82600160a060020a03811663c0ee0b8a8685856040518463ffffffff1660e060020a0281526004018084600160a060020a0316600160a060020a0316815260200183815260200180602001828103825283818151815260200191508051906020019080838360005b83811015611d35578082015183820152602001611d1d565b50505050905090810190601f168015611d625780820380516001836020036101000a031916815260200191505b50945050505050600060405180830381600087803b1515611d8257600080fd5b6102c65a03f11515611d9357600080fd5b5050505050505050565b6000600160075460a060020a900460ff166002811115611db957fe5b14611dc357600080fd5b50600160a060020a038116600081815260066020526040808220805492905590919082156108fc0290839051600060405180830381858888f193505050501515611e0c57600080fd5b81600160a060020a03167fd7dee2702d63ad89917b6a4da9981c90c4d24f8c2bdfd64c604ecae57d8d06518260405190815260200160405180910390a2600854611e5c908263ffffffff61151216565b6008555050565b6000600160a060020a0383161515611e7a57600080fd5b600160a060020a0333166000908152600b6020526040902054821115611e9f57600080fd5b600160a060020a0333166000908152600b6020526040902054611ec8908363ffffffff61151216565b600160a060020a033381166000908152600b60205260408082209390935590851681522054611efd908363ffffffff61150316565b600160a060020a038085166000818152600b6020526040908190209390935591339091169060008051602061285b8339815191529085905190815260200160405180910390a350600192915050565b60055433600160a060020a03908116911614611f6757600080fd5b600160a060020a0381161515611f7c57600080fd5b600554600160a060020a0380831691167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360058054600160a060020a031916600160a060020a0392909216919091179055565b600060075460a060020a900460ff166002811115611ff457fe5b14611ffe57600080fd5b600160a060020a038216600090815260066020526040902054612027908263ffffffff61150316565b600160a060020a038316600090815260066020526040902055600854611e5c908263ffffffff61150316565b3b90565b600080612077731d3b2638a7cc9f2cb3d298a3da7a90b67e5506ed612053565b11156120e75760008054600160a060020a031916731d3b2638a7cc9f2cb3d298a3da7a90b67e5506ed1790556120df60408051908101604052600b81527f6574685f6d61696e6e65740000000000000000000000000000000000000000006020820152612775565b506001610f76565b600061210673c03a2615d5efaf5f49f60b7bb6583eaec212fdf1612053565b111561216e5760008054600160a060020a03191673c03a2615d5efaf5f49f60b7bb6583eaec212fdf11790556120df60408051908101604052600c81527f6574685f726f707374656e3300000000000000000000000000000000000000006020820152612775565b600061218d73b7a07bcf2ba2f2703b24c0691b5278999c59ac7e612053565b11156121f55760008054600160a060020a03191673b7a07bcf2ba2f2703b24c0691b5278999c59ac7e1790556120df60408051908101604052600981527f6574685f6b6f76616e00000000000000000000000000000000000000000000006020820152612775565b600061221473146500cfd35b22e4a392fe0adc06de1a1368ed48612053565b111561227c5760008054600160a060020a03191673146500cfd35b22e4a392fe0adc06de1a1368ed481790556120df60408051908101604052600b81527f6574685f72696e6b6562790000000000000000000000000000000000000000006020820152612775565b600061229b736f485c8bf6fc43ea212e93bbf8ce046c7f1cb475612053565b11156122cf575060008054600160a060020a031916736f485c8bf6fc43ea212e93bbf8ce046c7f1cb4751790556001610f76565b60006122ee7320e12a1f859b3feae5fb2a0a32c18f5a65555bbf612053565b1115612322575060008054600160a060020a0319167320e12a1f859b3feae5fb2a0a32c18f5a65555bbf1790556001610f76565b60006123417351efaf4c8b3c9afbd5ab9f4bbc82784ab6ef8faa612053565b1115612375575060008054600160a060020a0319167351efaf4c8b3c9afbd5ab9f4bbc82784ab6ef8faa1790556001610f76565b506000919050565b600080548190600160a060020a031615806123aa57506000546123a890600160a060020a0316612053565b155b156123bb576123b96000612057565b505b60008054600160a060020a0316906338cc483190604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b151561240457600080fd5b6102c65a03f1151561241557600080fd5b5050506040518051600154600160a060020a0390811691161490506124b85760008054600160a060020a0316906338cc483190604051602001526040518163ffffffff1660e060020a028152600401602060405180830381600087803b151561247d57600080fd5b6102c65a03f1151561248e57600080fd5b505050604051805160018054600160a060020a031916600160a060020a0392909216919091179055505b600154600160a060020a031663524f3889856000604051602001526040518263ffffffff1660e060020a0281526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561252257808201518382015260200161250a565b50505050905090810190601f16801561254f5780820380516001836020036101000a031916815260200191505b5092505050602060405180830381600087803b151561256d57600080fd5b6102c65a03f1151561257e57600080fd5b5050506040518051915050670de0b6b3a764000062030d403a02018111156125a957600091506126ee565b600154600160a060020a031663adf59f99828787876000604051602001526040518563ffffffff1660e060020a028152600401808481526020018060200180602001838103835285818151815260200191508051906020019080838360005b83811015612620578082015183820152602001612608565b50505050905090810190601f16801561264d5780820380516001836020036101000a031916815260200191505b50838103825284818151815260200191508051906020019080838360005b8381101561268357808201518382015260200161266b565b50505050905090810190601f1680156126b05780820380516001836020036101000a031916815260200191505b50955050505050506020604051808303818588803b15156126d057600080fd5b6125ee5a03f115156126e157600080fd5b5050505060405180519250505b509392505050565b600060075460a060020a900460ff16600281111561271057fe5b1461271a57600080fd5b62ed4e0042016009556007805474ff0000000000000000000000000000000000000000191660a060020a1790557f599d8e5a83cffb867d051598c4d70e805d59802d8081c1c7d6dffc5b6aca2b8960405160405180910390a1565b6002818051610d5c92916020019061279a565b60206040519081016040526000815290565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106127db57805160ff1916838001178555612808565b82800160010185558215612808579182015b828111156128085782518255916020019190600101906127ed565b50612814929150612818565b5090565b610e5791905b80821115612814576000815560010161281e565b60118054600160a060020a03191673d8a56fb51b86e668b5665e83e0a31e36965783331790555600ddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3efa165627a7a72305820de64f3398b786c26ee666fd58e9e96ef2a0eb4681c18907046a26e199791e04f0029

   Swarm Source:
bzzr://de64f3398b786c26ee666fd58e9e96ef2a0eb4681c18907046a26e199791e04f

 

View All
Block Age txn Difficulty GasUsed Reward
View All
Block Age UncleNumber Difficulty GasUsed Reward
Make sure to use the "downvote" button for any spammy posts, and the "upvote" for interesting conversations.