ETH Price: $3,179.54 (-7.81%)
Gas: 5 Gwei

Token

Gener8tive K-Compositions (GꞢ)
 

Overview

Max Total Supply

250 GꞢ

Holders

131

Market

Volume (24H)

N/A

Min Price (24H)

N/A

Max Price (24H)

N/A

Other Info

Balance
0 GꞢ
0xdb2aa1aa981f575b58e5ee31622ef01bb198d721
Loading...
Loading
Loading...
Loading
Loading...
Loading

OVERVIEW

Minimalistic, unique art Compositions generated from on-chain algorithms. The 3rd ever full generative NFT project from April 2019.

# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
Gener8tiveKBlocksERC721

Compiler Version
v0.5.2+commit.1df8f40c

Optimization Enabled:
No with 200 runs

Other Settings:
default evmVersion

Contract Source Code (Solidity)

/**
 *Submitted for verification at Etherscan.io on 2019-04-27
*/

pragma solidity ^0.5.2;
pragma experimental ABIEncoderV2;
// produced by the Solididy File Flattener (c) David Appleton 2018
// contact : [email protected]
// released under Apache 2.0 licence
// input  /Users/yurivisser/Dev/gener8tive/contracts/Gener8tiveKBlocksERC721.sol
// flattened :  Saturday, 27-Apr-19 00:28:41 UTC
contract Ownable {
    address private _owner;

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

    /**
     * @dev The Ownable constructor sets the original `owner` of the contract to the sender
     * account.
     */
    constructor () internal {
        _owner = msg.sender;
        emit OwnershipTransferred(address(0), _owner);
    }

    /**
     * @return the address of the owner.
     */
    function owner() public view returns (address) {
        return _owner;
    }

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

    /**
     * @return true if `msg.sender` is the owner of the contract.
     */
    function isOwner() public view returns (bool) {
        return msg.sender == _owner;
    }

    /**
     * @dev Allows the current owner to relinquish control of the contract.
     * It will not be possible to call the functions with the `onlyOwner`
     * modifier anymore.
     * @notice Renouncing ownership will leave the contract without an owner,
     * thereby removing any functionality that is only available to the owner.
     */
    function renounceOwnership() public onlyOwner {
        emit OwnershipTransferred(_owner, address(0));
        _owner = address(0);
    }

    /**
     * @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 {
        _transferOwnership(newOwner);
    }

    /**
     * @dev Transfers control of the contract to a newOwner.
     * @param newOwner The address to transfer ownership to.
     */
    function _transferOwnership(address newOwner) internal {
        require(newOwner != address(0));
        emit OwnershipTransferred(_owner, newOwner);
        _owner = newOwner;
    }
}

contract solcChecker {
/* INCOMPATIBLE SOLC: import the following instead: "github.com/oraclize/ethereum-api/oraclizeAPI_0.4.sol" */ function f(bytes calldata x) external;
}

contract OraclizeI {

    address public cbAddress;

    function setProofType(byte _proofType) external;
    function setCustomGasPrice(uint _gasPrice) external;
    function getPrice(string memory _datasource) public returns (uint _dsprice);
    function randomDS_getSessionPubKeyHash() external view returns (bytes32 _sessionKeyHash);
    function getPrice(string memory _datasource, uint _gasLimit) public returns (uint _dsprice);
    function queryN(uint _timestamp, string memory _datasource, bytes memory _argN) public payable returns (bytes32 _id);
    function query(uint _timestamp, string calldata _datasource, string calldata _arg) external payable returns (bytes32 _id);
    function query2(uint _timestamp, string memory _datasource, string memory _arg1, string memory _arg2) public payable returns (bytes32 _id);
    function query_withGasLimit(uint _timestamp, string calldata _datasource, string calldata _arg, uint _gasLimit) external payable returns (bytes32 _id);
    function queryN_withGasLimit(uint _timestamp, string calldata _datasource, bytes calldata _argN, uint _gasLimit) external payable returns (bytes32 _id);
    function query2_withGasLimit(uint _timestamp, string calldata _datasource, string calldata _arg1, string calldata _arg2, uint _gasLimit) external payable returns (bytes32 _id);
}

contract OraclizeAddrResolverI {
    function getAddress() public returns (address _address);
}
/*

Begin solidity-cborutils

https://github.com/smartcontractkit/solidity-cborutils

MIT License

Copyright (c) 2018 SmartContract ChainLink, 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.

*/
library Buffer {

    struct buffer {
        bytes buf;
        uint capacity;
    }

    function init(buffer memory _buf, uint _capacity) internal pure {
        uint capacity = _capacity;
        if (capacity % 32 != 0) {
            capacity += 32 - (capacity % 32);
        }
        _buf.capacity = capacity; // Allocate space for the buffer data
        assembly {
            let ptr := mload(0x40)
            mstore(_buf, ptr)
            mstore(ptr, 0)
            mstore(0x40, add(ptr, capacity))
        }
    }

    function resize(buffer memory _buf, uint _capacity) private pure {
        bytes memory oldbuf = _buf.buf;
        init(_buf, _capacity);
        append(_buf, oldbuf);
    }

    function max(uint _a, uint _b) private pure returns (uint _max) {
        if (_a > _b) {
            return _a;
        }
        return _b;
    }
    /**
      * @dev Appends a byte array to the end of the buffer. Resizes if doing so
      *      would exceed the capacity of the buffer.
      * @param _buf The buffer to append to.
      * @param _data The data to append.
      * @return The original buffer.
      *
      */
    function append(buffer memory _buf, bytes memory _data) internal pure returns (buffer memory _buffer) {
        if (_data.length + _buf.buf.length > _buf.capacity) {
            resize(_buf, max(_buf.capacity, _data.length) * 2);
        }
        uint dest;
        uint src;
        uint len = _data.length;
        assembly {
            let bufptr := mload(_buf) // Memory address of the buffer data
            let buflen := mload(bufptr) // Length of existing buffer data
            dest := add(add(bufptr, buflen), 32) // Start address = buffer address + buffer length + sizeof(buffer length)
            mstore(bufptr, add(buflen, mload(_data))) // Update buffer length
            src := add(_data, 32)
        }
        for(; len >= 32; len -= 32) { // Copy word-length chunks while possible
            assembly {
                mstore(dest, mload(src))
            }
            dest += 32;
            src += 32;
        }
        uint mask = 256 ** (32 - len) - 1; // Copy remaining bytes
        assembly {
            let srcpart := and(mload(src), not(mask))
            let destpart := and(mload(dest), mask)
            mstore(dest, or(destpart, srcpart))
        }
        return _buf;
    }
    /**
      *
      * @dev Appends a byte to the end of the buffer. Resizes if doing so would
      * exceed the capacity of the buffer.
      * @param _buf The buffer to append to.
      * @param _data The data to append.
      * @return The original buffer.
      *
      */
    function append(buffer memory _buf, uint8 _data) internal pure {
        if (_buf.buf.length + 1 > _buf.capacity) {
            resize(_buf, _buf.capacity * 2);
        }
        assembly {
            let bufptr := mload(_buf) // Memory address of the buffer data
            let buflen := mload(bufptr) // Length of existing buffer data
            let dest := add(add(bufptr, buflen), 32) // Address = buffer address + buffer length + sizeof(buffer length)
            mstore8(dest, _data)
            mstore(bufptr, add(buflen, 1)) // Update buffer length
        }
    }
    /**
      *
      * @dev Appends a byte to the end of the buffer. Resizes if doing so would
      * exceed the capacity of the buffer.
      * @param _buf The buffer to append to.
      * @param _data The data to append.
      * @return The original buffer.
      *
      */
    function appendInt(buffer memory _buf, uint _data, uint _len) internal pure returns (buffer memory _buffer) {
        if (_len + _buf.buf.length > _buf.capacity) {
            resize(_buf, max(_buf.capacity, _len) * 2);
        }
        uint mask = 256 ** _len - 1;
        assembly {
            let bufptr := mload(_buf) // Memory address of the buffer data
            let buflen := mload(bufptr) // Length of existing buffer data
            let dest := add(add(bufptr, buflen), _len) // Address = buffer address + buffer length + sizeof(buffer length) + len
            mstore(dest, or(and(mload(dest), not(mask)), _data))
            mstore(bufptr, add(buflen, _len)) // Update buffer length
        }
        return _buf;
    }
}

library CBOR {

    using Buffer for Buffer.buffer;

    uint8 private constant MAJOR_TYPE_INT = 0;
    uint8 private constant MAJOR_TYPE_MAP = 5;
    uint8 private constant MAJOR_TYPE_BYTES = 2;
    uint8 private constant MAJOR_TYPE_ARRAY = 4;
    uint8 private constant MAJOR_TYPE_STRING = 3;
    uint8 private constant MAJOR_TYPE_NEGATIVE_INT = 1;
    uint8 private constant MAJOR_TYPE_CONTENT_FREE = 7;

    function encodeType(Buffer.buffer memory _buf, uint8 _major, uint _value) private pure {
        if (_value <= 23) {
            _buf.append(uint8((_major << 5) | _value));
        } else if (_value <= 0xFF) {
            _buf.append(uint8((_major << 5) | 24));
            _buf.appendInt(_value, 1);
        } else if (_value <= 0xFFFF) {
            _buf.append(uint8((_major << 5) | 25));
            _buf.appendInt(_value, 2);
        } else if (_value <= 0xFFFFFFFF) {
            _buf.append(uint8((_major << 5) | 26));
            _buf.appendInt(_value, 4);
        } else if (_value <= 0xFFFFFFFFFFFFFFFF) {
            _buf.append(uint8((_major << 5) | 27));
            _buf.appendInt(_value, 8);
        }
    }

    function encodeIndefiniteLengthType(Buffer.buffer memory _buf, uint8 _major) private pure {
        _buf.append(uint8((_major << 5) | 31));
    }

    function encodeUInt(Buffer.buffer memory _buf, uint _value) internal pure {
        encodeType(_buf, MAJOR_TYPE_INT, _value);
    }

    function encodeInt(Buffer.buffer memory _buf, int _value) internal pure {
        if (_value >= 0) {
            encodeType(_buf, MAJOR_TYPE_INT, uint(_value));
        } else {
            encodeType(_buf, MAJOR_TYPE_NEGATIVE_INT, uint(-1 - _value));
        }
    }

    function encodeBytes(Buffer.buffer memory _buf, bytes memory _value) internal pure {
        encodeType(_buf, MAJOR_TYPE_BYTES, _value.length);
        _buf.append(_value);
    }

    function encodeString(Buffer.buffer memory _buf, string memory _value) internal pure {
        encodeType(_buf, MAJOR_TYPE_STRING, bytes(_value).length);
        _buf.append(bytes(_value));
    }

    function startArray(Buffer.buffer memory _buf) internal pure {
        encodeIndefiniteLengthType(_buf, MAJOR_TYPE_ARRAY);
    }

    function startMap(Buffer.buffer memory _buf) internal pure {
        encodeIndefiniteLengthType(_buf, MAJOR_TYPE_MAP);
    }

    function endSequence(Buffer.buffer memory _buf) internal pure {
        encodeIndefiniteLengthType(_buf, MAJOR_TYPE_CONTENT_FREE);
    }
}
/*

End solidity-cborutils

*/
contract usingOraclize {

    using CBOR for Buffer.buffer;

    OraclizeI oraclize;
    OraclizeAddrResolverI OAR;

    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_Ledger = 0x30;
    byte constant proofType_Native = 0xF0;
    byte constant proofStorage_IPFS = 0x01;
    byte constant proofType_Android = 0x40;
    byte constant proofType_TLSNotary = 0x10;

    string oraclize_network_name;
    uint8 constant networkID_auto = 0;
    uint8 constant networkID_morden = 2;
    uint8 constant networkID_mainnet = 1;
    uint8 constant networkID_testnet = 2;
    uint8 constant networkID_consensys = 161;

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

    modifier oraclizeAPI {
        if ((address(OAR) == address(0)) || (getCodeSize(address(OAR)) == 0)) {
            oraclize_setNetwork(networkID_auto);
        }
        if (address(oraclize) != OAR.getAddress()) {
            oraclize = OraclizeI(OAR.getAddress());
        }
        _;
    }

    modifier oraclize_randomDS_proofVerify(bytes32 _queryId, string memory _result, bytes memory _proof) {
        // RandomDS Proof Step 1: The prefix has to match 'LP\x01' (Ledger Proof version 1)
        require((_proof[0] == "L") && (_proof[1] == "P") && (uint8(_proof[2]) == uint8(1)));
        bool proofVerified = oraclize_randomDS_proofVerify__main(_proof, _queryId, bytes(_result), oraclize_getNetworkName());
        require(proofVerified);
        _;
    }

    function oraclize_setNetwork(uint8 _networkID) internal returns (bool _networkSet) {
      return oraclize_setNetwork();
      _networkID; // silence the warning and remain backwards compatible
    }

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

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

    function oraclize_setNetwork() internal returns (bool _networkSet) {
        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(0xa2998EFD205FB9D4B4963aFb70778D6354ad3A41) > 0) { //goerli testnet
            OAR = OraclizeAddrResolverI(0xa2998EFD205FB9D4B4963aFb70778D6354ad3A41);
            oraclize_setNetworkName("eth_goerli");
            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 memory _result) public {
        __callback(_myid, _result, new bytes(0));
    }

    function __callback(bytes32 _myid, string memory _result, bytes memory _proof) public {
      return;
      _myid; _result; _proof; // Silence compiler warnings
    }

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

    function oraclize_getPrice(string memory _datasource, uint _gasLimit) oraclizeAPI internal returns (uint _queryPrice) {
        return oraclize.getPrice(_datasource, _gasLimit);
    }

    function oraclize_query(string memory _datasource, string memory _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 memory _datasource, string memory _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 memory _datasource, string memory _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 memory _datasource, string memory _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 memory _datasource, string memory _arg1, string memory _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 memory _datasource, string memory _arg1, string memory _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 memory _datasource, string memory _arg1, string memory _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 memory _datasource, string memory _arg1, string memory _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 memory _datasource, string[] memory _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 memory _datasource, string[] memory _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 memory _datasource, string[] memory _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 memory _datasource, string[] memory _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 memory _datasource, string[1] memory _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 memory _datasource, string[1] memory _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 memory _datasource, string[1] memory _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 memory _datasource, string[1] memory _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 memory _datasource, string[2] memory _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 memory _datasource, string[2] memory _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 memory _datasource, string[2] memory _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 memory _datasource, string[2] memory _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 memory _datasource, string[3] memory _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 memory _datasource, string[3] memory _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 memory _datasource, string[3] memory _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 memory _datasource, string[3] memory _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 memory _datasource, string[4] memory _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 memory _datasource, string[4] memory _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 memory _datasource, string[4] memory _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 memory _datasource, string[4] memory _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 memory _datasource, string[5] memory _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 memory _datasource, string[5] memory _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 memory _datasource, string[5] memory _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 memory _datasource, string[5] memory _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 memory _datasource, bytes[] memory _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 memory _datasource, bytes[] memory _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 memory _datasource, bytes[] memory _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 memory _datasource, bytes[] memory _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 memory _datasource, bytes[1] memory _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 memory _datasource, bytes[1] memory _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 memory _datasource, bytes[1] memory _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 memory _datasource, bytes[1] memory _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 memory _datasource, bytes[2] memory _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 memory _datasource, bytes[2] memory _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 memory _datasource, bytes[2] memory _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 memory _datasource, bytes[2] memory _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 memory _datasource, bytes[3] memory _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 memory _datasource, bytes[3] memory _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 memory _datasource, bytes[3] memory _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 memory _datasource, bytes[3] memory _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 memory _datasource, bytes[4] memory _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 memory _datasource, bytes[4] memory _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 memory _datasource, bytes[4] memory _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 memory _datasource, bytes[4] memory _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 memory _datasource, bytes[5] memory _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 memory _datasource, bytes[5] memory _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 memory _datasource, bytes[5] memory _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 memory _datasource, bytes[5] memory _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_setProof(byte _proofP) oraclizeAPI internal {
        return oraclize.setProofType(_proofP);
    }


    function oraclize_cbAddress() oraclizeAPI internal returns (address _callbackAddress) {
        return oraclize.cbAddress();
    }

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

    function oraclize_setCustomGasPrice(uint _gasPrice) oraclizeAPI internal {
        return oraclize.setCustomGasPrice(_gasPrice);
    }

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

    function parseAddr(string memory _a) internal pure returns (address _parsedAddress) {
        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(uint8(tmp[i]));
            b2 = uint160(uint8(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 memory _a, string memory _b) internal pure returns (int _returnCode) {
        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 memory _haystack, string memory _needle) internal pure returns (int _returnCode) {
        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 memory _a, string memory _b) internal pure returns (string memory _concatenatedString) {
        return strConcat(_a, _b, "", "", "");
    }

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

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

    function strConcat(string memory _a, string memory _b, string memory _c, string memory _d, string memory _e) internal pure returns (string memory _concatenatedString) {
        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;
        uint i = 0;
        for (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 safeParseInt(string memory _a) internal pure returns (uint _parsedInt) {
        return safeParseInt(_a, 0);
    }

    function safeParseInt(string memory _a, uint _b) internal pure returns (uint _parsedInt) {
        bytes memory bresult = bytes(_a);
        uint mint = 0;
        bool decimals = false;
        for (uint i = 0; i < bresult.length; i++) {
            if ((uint(uint8(bresult[i])) >= 48) && (uint(uint8(bresult[i])) <= 57)) {
                if (decimals) {
                   if (_b == 0) break;
                    else _b--;
                }
                mint *= 10;
                mint += uint(uint8(bresult[i])) - 48;
            } else if (uint(uint8(bresult[i])) == 46) {
                require(!decimals, 'More than one decimal encountered in string!');
                decimals = true;
            } else {
                revert("Non-numeral character encountered in string!");
            }
        }
        if (_b > 0) {
            mint *= 10 ** _b;
        }
        return mint;
    }

    function parseInt(string memory _a) internal pure returns (uint _parsedInt) {
        return parseInt(_a, 0);
    }

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

    function uint2str(uint _i) internal pure returns (string memory _uintAsString) {
        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(uint8(48 + _i % 10));
            _i /= 10;
        }
        return string(bstr);
    }

    function stra2cbor(string[] memory _arr) internal pure returns (bytes memory _cborEncoding) {
        safeMemoryCleaner();
        Buffer.buffer memory buf;
        Buffer.init(buf, 1024);
        buf.startArray();
        for (uint i = 0; i < _arr.length; i++) {
            buf.encodeString(_arr[i]);
        }
        buf.endSequence();
        return buf.buf;
    }

    function ba2cbor(bytes[] memory _arr) internal pure returns (bytes memory _cborEncoding) {
        safeMemoryCleaner();
        Buffer.buffer memory buf;
        Buffer.init(buf, 1024);
        buf.startArray();
        for (uint i = 0; i < _arr.length; i++) {
            buf.encodeBytes(_arr[i]);
        }
        buf.endSequence();
        return buf.buf;
    }

    function oraclize_newRandomDSQuery(uint _delay, uint _nbytes, uint _customGasLimit) internal returns (bytes32 _queryId) {
        require((_nbytes > 0) && (_nbytes <= 32));
        _delay *= 10; // Convert from seconds to ledger timer ticks
        bytes memory nbytes = new bytes(1);
        nbytes[0] = byte(uint8(_nbytes));
        bytes memory unonce = new bytes(32);
        bytes memory sessionKeyHash = new bytes(32);
        bytes32 sessionKeyHash_bytes32 = oraclize_randomDS_getSessionPubKeyHash();
        assembly {
            mstore(unonce, 0x20)
            /*
             The following variables can be relaxed.
             Check the relaxed random contract at https://github.com/oraclize/ethereum-examples
             for an idea on how to override and replace commit hash variables.
            */
            mstore(add(unonce, 0x20), xor(blockhash(sub(number, 1)), xor(coinbase, timestamp)))
            mstore(sessionKeyHash, 0x20)
            mstore(add(sessionKeyHash, 0x20), sessionKeyHash_bytes32)
        }
        bytes memory delay = new bytes(32);
        assembly {
            mstore(add(delay, 0x20), _delay)
        }
        bytes memory delay_bytes8 = new bytes(8);
        copyBytes(delay, 24, 8, delay_bytes8, 0);
        bytes[4] memory args = [unonce, nbytes, sessionKeyHash, delay];
        bytes32 queryId = oraclize_query("random", args, _customGasLimit);
        bytes memory delay_bytes8_left = new bytes(8);
        assembly {
            let x := mload(add(delay_bytes8, 0x20))
            mstore8(add(delay_bytes8_left, 0x27), div(x, 0x100000000000000000000000000000000000000000000000000000000000000))
            mstore8(add(delay_bytes8_left, 0x26), div(x, 0x1000000000000000000000000000000000000000000000000000000000000))
            mstore8(add(delay_bytes8_left, 0x25), div(x, 0x10000000000000000000000000000000000000000000000000000000000))
            mstore8(add(delay_bytes8_left, 0x24), div(x, 0x100000000000000000000000000000000000000000000000000000000))
            mstore8(add(delay_bytes8_left, 0x23), div(x, 0x1000000000000000000000000000000000000000000000000000000))
            mstore8(add(delay_bytes8_left, 0x22), div(x, 0x10000000000000000000000000000000000000000000000000000))
            mstore8(add(delay_bytes8_left, 0x21), div(x, 0x100000000000000000000000000000000000000000000000000))
            mstore8(add(delay_bytes8_left, 0x20), div(x, 0x1000000000000000000000000000000000000000000000000))
        }
        oraclize_randomDS_setCommitment(queryId, keccak256(abi.encodePacked(delay_bytes8_left, args[1], sha256(args[0]), args[2])));
        return queryId;
    }

    function oraclize_randomDS_setCommitment(bytes32 _queryId, bytes32 _commitment) internal {
        oraclize_randomDS_args[_queryId] = _commitment;
    }

    function verifySig(bytes32 _tosignh, bytes memory _dersig, bytes memory _pubkey) internal returns (bool _sigVerified) {
        bool sigok;
        address signer;
        bytes32 sigr;
        bytes32 sigs;
        bytes memory sigr_ = new bytes(32);
        uint offset = 4 + (uint(uint8(_dersig[3])) - 0x20);
        sigr_ = copyBytes(_dersig, offset, 32, sigr_, 0);
        bytes memory sigs_ = new bytes(32);
        offset += 32 + 2;
        sigs_ = copyBytes(_dersig, offset + (uint(uint8(_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(uint160(uint256(keccak256(_pubkey)))) == signer) {
            return true;
        } else {
            (sigok, signer) = safer_ecrecover(_tosignh, 28, sigr, sigs);
            return (address(uint160(uint256(keccak256(_pubkey)))) == signer);
        }
    }

    function oraclize_randomDS_proofVerify__sessionKeyValidity(bytes memory _proof, uint _sig2offset) internal returns (bool _proofVerified) {
        bool sigok;
        // Random DS Proof Step 6: Verify the attestation signature, APPKEY1 must sign the sessionKey from the correct ledger app (CODEHASH)
        bytes memory sig2 = new bytes(uint(uint8(_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] = byte(uint8(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) {
            return false;
        }
        // Random DS Proof 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(uint8(_proof[3 + 65 + 1])) + 2);
        copyBytes(_proof, 3 + 65, sig3.length, sig3, 0);
        sigok = verifySig(sha256(tosign3), sig3, LEDGERKEY);
        return sigok;
    }

    function oraclize_randomDS_proofVerify__returnCode(bytes32 _queryId, string memory _result, bytes memory _proof) internal returns (uint8 _returnCode) {
        // Random DS Proof Step 1: The prefix has to match 'LP\x01' (Ledger Proof version 1)
        if ((_proof[0] != "L") || (_proof[1] != "P") || (uint8(_proof[2]) != uint8(1))) {
            return 1;
        }
        bool proofVerified = oraclize_randomDS_proofVerify__main(_proof, _queryId, bytes(_result), oraclize_getNetworkName());
        if (!proofVerified) {
            return 2;
        }
        return 0;
    }

    function matchBytes32Prefix(bytes32 _content, bytes memory _prefix, uint _nRandomBytes) internal pure returns (bool _matchesPrefix) {
        bool match_ = true;
        require(_prefix.length == _nRandomBytes);
        for (uint256 i = 0; i< _nRandomBytes; i++) {
            if (_content[i] != _prefix[i]) {
                match_ = false;
            }
        }
        return match_;
    }

    function oraclize_randomDS_proofVerify__main(bytes memory _proof, bytes32 _queryId, bytes memory _result, string memory _contextName) internal returns (bool _proofVerified) {
        // Random DS Proof Step 2: The unique keyhash has to match with the sha256 of (context name + _queryId)
        uint ledgerProofLength = 3 + 65 + (uint(uint8(_proof[3 + 65 + 1])) + 2) + 32;
        bytes memory keyhash = new bytes(32);
        copyBytes(_proof, ledgerProofLength, 32, keyhash, 0);
        if (!(keccak256(keyhash) == keccak256(abi.encodePacked(sha256(abi.encodePacked(_contextName, _queryId)))))) {
            return false;
        }
        bytes memory sig1 = new bytes(uint(uint8(_proof[ledgerProofLength + (32 + 8 + 1 + 32) + 1])) + 2);
        copyBytes(_proof, ledgerProofLength + (32 + 8 + 1 + 32), sig1.length, sig1, 0);
        // Random DS Proof 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(uint8(_proof[ledgerProofLength + 32 + 8])))) {
            return false;
        }
        // Random DS Proof Step 4: Commitment match verification, keccak256(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] == keccak256(abi.encodePacked(commitmentSlice1, sessionPubkeyHash))) { //unonce, nbytes and sessionKeyHash match
            delete oraclize_randomDS_args[_queryId];
        } else return false;
        // Random DS Proof 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]) {
            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 memory _from, uint _fromOffset, uint _length, bytes memory _to, uint _toOffset) internal pure returns (bytes memory _copiedBytes) {
        uint minLength = _length + _toOffset;
        require(_to.length >= minLength); // Buffer too small. Should be a better way?
        uint i = 32 + _fromOffset; // NOTE: the offset 32 is added to skip the `size` field of both bytes variables
        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 _success, address _recoveredAddress) {
        /*
         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)
            ret := call(3000, 1, 0, size, 128, size, 32) // NOTE: we can reuse the request memory because we deal with the return code.
            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 memory _sig) internal returns (bool _success, address _recoveredAddress) {
        bytes32 r;
        bytes32 s;
        uint8 v;
        if (_sig.length != 65) {
            return (false, address(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, address(0));
        }
        return safer_ecrecover(_hash, v, r, s);
    }

    function safeMemoryCleaner() internal pure {
        assembly {
            let fmem := mload(0x40)
            codecopy(fmem, codesize, sub(msize, fmem))
        }
    }
}
/*

END ORACLIZE_API

*/
interface IERC165 {
    /**
     * @notice Query if a contract implements an interface
     * @param interfaceId The interface identifier, as specified in ERC-165
     * @dev Interface identification is specified in ERC-165. This function
     * uses less than 30,000 gas.
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool);
}

library SafeMath {
    /**
     * @dev Multiplies two unsigned integers, reverts on overflow.
     */
    function mul(uint256 a, uint256 b) internal pure returns (uint256) {
        // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
        // benefit is lost if 'b' is also tested.
        // See: https://github.com/OpenZeppelin/openzeppelin-solidity/pull/522
        if (a == 0) {
            return 0;
        }

        uint256 c = a * b;
        require(c / a == b);

        return c;
    }

    /**
     * @dev Integer division of two unsigned integers truncating the quotient, reverts on division by zero.
     */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        // Solidity only automatically asserts when dividing by 0
        require(b > 0);
        uint256 c = a / b;
        // assert(a == b * c + a % b); // There is no case in which this doesn't hold

        return c;
    }

    /**
     * @dev Subtracts two unsigned integers, reverts on overflow (i.e. if subtrahend is greater than minuend).
     */
    function sub(uint256 a, uint256 b) internal pure returns (uint256) {
        require(b <= a);
        uint256 c = a - b;

        return c;
    }

    /**
     * @dev Adds two unsigned integers, reverts on overflow.
     */
    function add(uint256 a, uint256 b) internal pure returns (uint256) {
        uint256 c = a + b;
        require(c >= a);

        return c;
    }

    /**
     * @dev Divides two unsigned integers and returns the remainder (unsigned integer modulo),
     * reverts when dividing by zero.
     */
    function mod(uint256 a, uint256 b) internal pure returns (uint256) {
        require(b != 0);
        return a % b;
    }
}

contract IERC721Receiver {
    /**
     * @notice Handle the receipt of an NFT
     * @dev The ERC721 smart contract calls this function on the recipient
     * after a `safeTransfer`. This function MUST return the function selector,
     * otherwise the caller will revert the transaction. The selector to be
     * returned can be obtained as `this.onERC721Received.selector`. This
     * function MAY throw to revert and reject the transfer.
     * Note: the ERC721 contract address is always the message sender.
     * @param operator The address which called `safeTransferFrom` function
     * @param from The address which previously owned the token
     * @param tokenId The NFT identifier which is being transferred
     * @param data Additional data with no specified format
     * @return bytes4 `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`
     */
    function onERC721Received(address operator, address from, uint256 tokenId, bytes memory data)
    public returns (bytes4);
}

library Address {
    /**
     * Returns whether the target address is a contract
     * @dev This function will return false if invoked during the constructor of a contract,
     * as the code is not actually created until after the constructor finishes.
     * @param account address of the account to check
     * @return whether the target address is a contract
     */
    function isContract(address account) internal view returns (bool) {
        uint256 size;
        // XXX Currently there is no better way to check if there is a contract in an address
        // than to check the size of the code at that address.
        // See https://ethereum.stackexchange.com/a/14016/36603
        // for more details about how this works.
        // TODO Check this again before the Serenity release, because all addresses will be
        // contracts then.
        // solhint-disable-next-line no-inline-assembly
        assembly { size := extcodesize(account) }
        return size > 0;
    }
}

contract IERC721 is IERC165 {
    event Transfer(address indexed from, address indexed to, uint256 indexed tokenId);
    event Approval(address indexed owner, address indexed approved, uint256 indexed tokenId);
    event ApprovalForAll(address indexed owner, address indexed operator, bool approved);

    function balanceOf(address owner) public view returns (uint256 balance);
    function ownerOf(uint256 tokenId) public view returns (address owner);

    function approve(address to, uint256 tokenId) public;
    function getApproved(uint256 tokenId) public view returns (address operator);

    function setApprovalForAll(address operator, bool _approved) public;
    function isApprovedForAll(address owner, address operator) public view returns (bool);

    function transferFrom(address from, address to, uint256 tokenId) public;
    function safeTransferFrom(address from, address to, uint256 tokenId) public;

    function safeTransferFrom(address from, address to, uint256 tokenId, bytes memory data) public;
}

library Counters {
    using SafeMath for uint256;

    struct Counter {
        // This variable should never be directly accessed by users of the library: interactions must be restricted to
        // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add
        // this feature: see https://github.com/ethereum/solidity/issues/4637
        uint256 _value; // default: 0
    }

    function current(Counter storage counter) internal view returns (uint256) {
        return counter._value;
    }

    function increment(Counter storage counter) internal {
        counter._value += 1;
    }

    function decrement(Counter storage counter) internal {
        counter._value = counter._value.sub(1);
    }
}

contract ERC165 is IERC165 {
    bytes4 private constant _INTERFACE_ID_ERC165 = 0x01ffc9a7;
    /*
     * 0x01ffc9a7 ===
     *     bytes4(keccak256('supportsInterface(bytes4)'))
     */

    /**
     * @dev a mapping of interface id to whether or not it's supported
     */
    mapping(bytes4 => bool) private _supportedInterfaces;

    /**
     * @dev A contract implementing SupportsInterfaceWithLookup
     * implement ERC165 itself
     */
    constructor () internal {
        _registerInterface(_INTERFACE_ID_ERC165);
    }

    /**
     * @dev implement supportsInterface(bytes4) using a lookup table
     */
    function supportsInterface(bytes4 interfaceId) external view returns (bool) {
        return _supportedInterfaces[interfaceId];
    }

    /**
     * @dev internal method for registering an interface
     */
    function _registerInterface(bytes4 interfaceId) internal {
        require(interfaceId != 0xffffffff);
        _supportedInterfaces[interfaceId] = true;
    }
}

contract ERC721 is ERC165, IERC721 {
    using SafeMath for uint256;
    using Address for address;
    using Counters for Counters.Counter;

    // Equals to `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`
    // which can be also obtained as `IERC721Receiver(0).onERC721Received.selector`
    bytes4 private constant _ERC721_RECEIVED = 0x150b7a02;

    // Mapping from token ID to owner
    mapping (uint256 => address) private _tokenOwner;

    // Mapping from token ID to approved address
    mapping (uint256 => address) private _tokenApprovals;

    // Mapping from owner to number of owned token
    mapping (address => Counters.Counter) private _ownedTokensCount;

    // Mapping from owner to operator approvals
    mapping (address => mapping (address => bool)) private _operatorApprovals;

    bytes4 private constant _INTERFACE_ID_ERC721 = 0x80ac58cd;
    /*
     * 0x80ac58cd ===
     *     bytes4(keccak256('balanceOf(address)')) ^
     *     bytes4(keccak256('ownerOf(uint256)')) ^
     *     bytes4(keccak256('approve(address,uint256)')) ^
     *     bytes4(keccak256('getApproved(uint256)')) ^
     *     bytes4(keccak256('setApprovalForAll(address,bool)')) ^
     *     bytes4(keccak256('isApprovedForAll(address,address)')) ^
     *     bytes4(keccak256('transferFrom(address,address,uint256)')) ^
     *     bytes4(keccak256('safeTransferFrom(address,address,uint256)')) ^
     *     bytes4(keccak256('safeTransferFrom(address,address,uint256,bytes)'))
     */

    constructor () public {
        // register the supported interfaces to conform to ERC721 via ERC165
        _registerInterface(_INTERFACE_ID_ERC721);
    }

    /**
     * @dev Gets the balance of the specified address
     * @param owner address to query the balance of
     * @return uint256 representing the amount owned by the passed address
     */
    function balanceOf(address owner) public view returns (uint256) {
        require(owner != address(0));
        return _ownedTokensCount[owner].current();
    }

    /**
     * @dev Gets the owner of the specified token ID
     * @param tokenId uint256 ID of the token to query the owner of
     * @return address currently marked as the owner of the given token ID
     */
    function ownerOf(uint256 tokenId) public view returns (address) {
        address owner = _tokenOwner[tokenId];
        require(owner != address(0));
        return owner;
    }

    /**
     * @dev Approves another address to transfer the given token ID
     * The zero address indicates there is no approved address.
     * There can only be one approved address per token at a given time.
     * Can only be called by the token owner or an approved operator.
     * @param to address to be approved for the given token ID
     * @param tokenId uint256 ID of the token to be approved
     */
    function approve(address to, uint256 tokenId) public {
        address owner = ownerOf(tokenId);
        require(to != owner);
        require(msg.sender == owner || isApprovedForAll(owner, msg.sender));

        _tokenApprovals[tokenId] = to;
        emit Approval(owner, to, tokenId);
    }

    /**
     * @dev Gets the approved address for a token ID, or zero if no address set
     * Reverts if the token ID does not exist.
     * @param tokenId uint256 ID of the token to query the approval of
     * @return address currently approved for the given token ID
     */
    function getApproved(uint256 tokenId) public view returns (address) {
        require(_exists(tokenId));
        return _tokenApprovals[tokenId];
    }

    /**
     * @dev Sets or unsets the approval of a given operator
     * An operator is allowed to transfer all tokens of the sender on their behalf
     * @param to operator address to set the approval
     * @param approved representing the status of the approval to be set
     */
    function setApprovalForAll(address to, bool approved) public {
        require(to != msg.sender);
        _operatorApprovals[msg.sender][to] = approved;
        emit ApprovalForAll(msg.sender, to, approved);
    }

    /**
     * @dev Tells whether an operator is approved by a given owner
     * @param owner owner address which you want to query the approval of
     * @param operator operator address which you want to query the approval of
     * @return bool whether the given operator is approved by the given owner
     */
    function isApprovedForAll(address owner, address operator) public view returns (bool) {
        return _operatorApprovals[owner][operator];
    }

    /**
     * @dev Transfers the ownership of a given token ID to another address
     * Usage of this method is discouraged, use `safeTransferFrom` whenever possible
     * Requires the msg.sender to be the owner, approved, or operator
     * @param from current owner of the token
     * @param to address to receive the ownership of the given token ID
     * @param tokenId uint256 ID of the token to be transferred
     */
    function transferFrom(address from, address to, uint256 tokenId) public {
        require(_isApprovedOrOwner(msg.sender, tokenId));

        _transferFrom(from, to, tokenId);
    }

    /**
     * @dev Safely transfers the ownership of a given token ID to another address
     * If the target address is a contract, it must implement `onERC721Received`,
     * which is called upon a safe transfer, and return the magic value
     * `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`; otherwise,
     * the transfer is reverted.
     * Requires the msg.sender to be the owner, approved, or operator
     * @param from current owner of the token
     * @param to address to receive the ownership of the given token ID
     * @param tokenId uint256 ID of the token to be transferred
     */
    function safeTransferFrom(address from, address to, uint256 tokenId) public {
        safeTransferFrom(from, to, tokenId, "");
    }

    /**
     * @dev Safely transfers the ownership of a given token ID to another address
     * If the target address is a contract, it must implement `onERC721Received`,
     * which is called upon a safe transfer, and return the magic value
     * `bytes4(keccak256("onERC721Received(address,address,uint256,bytes)"))`; otherwise,
     * the transfer is reverted.
     * Requires the msg.sender to be the owner, approved, or operator
     * @param from current owner of the token
     * @param to address to receive the ownership of the given token ID
     * @param tokenId uint256 ID of the token to be transferred
     * @param _data bytes data to send along with a safe transfer check
     */
    function safeTransferFrom(address from, address to, uint256 tokenId, bytes memory _data) public {
        transferFrom(from, to, tokenId);
        require(_checkOnERC721Received(from, to, tokenId, _data));
    }

    /**
     * @dev Returns whether the specified token exists
     * @param tokenId uint256 ID of the token to query the existence of
     * @return bool whether the token exists
     */
    function _exists(uint256 tokenId) internal view returns (bool) {
        address owner = _tokenOwner[tokenId];
        return owner != address(0);
    }

    /**
     * @dev Returns whether the given spender can transfer a given token ID
     * @param spender address of the spender to query
     * @param tokenId uint256 ID of the token to be transferred
     * @return bool whether the msg.sender is approved for the given token ID,
     * is an operator of the owner, or is the owner of the token
     */
    function _isApprovedOrOwner(address spender, uint256 tokenId) internal view returns (bool) {
        address owner = ownerOf(tokenId);
        return (spender == owner || getApproved(tokenId) == spender || isApprovedForAll(owner, spender));
    }

    /**
     * @dev Internal function to mint a new token
     * Reverts if the given token ID already exists
     * @param to The address that will own the minted token
     * @param tokenId uint256 ID of the token to be minted
     */
    function _mint(address to, uint256 tokenId) internal {
        require(to != address(0));
        require(!_exists(tokenId));

        _tokenOwner[tokenId] = to;
        _ownedTokensCount[to].increment();

        emit Transfer(address(0), to, tokenId);
    }

    /**
     * @dev Internal function to burn a specific token
     * Reverts if the token does not exist
     * Deprecated, use _burn(uint256) instead.
     * @param owner owner of the token to burn
     * @param tokenId uint256 ID of the token being burned
     */
    function _burn(address owner, uint256 tokenId) internal {
        require(ownerOf(tokenId) == owner);

        _clearApproval(tokenId);

        _ownedTokensCount[owner].decrement();
        _tokenOwner[tokenId] = address(0);

        emit Transfer(owner, address(0), tokenId);
    }

    /**
     * @dev Internal function to burn a specific token
     * Reverts if the token does not exist
     * @param tokenId uint256 ID of the token being burned
     */
    function _burn(uint256 tokenId) internal {
        _burn(ownerOf(tokenId), tokenId);
    }

    /**
     * @dev Internal function to transfer ownership of a given token ID to another address.
     * As opposed to transferFrom, this imposes no restrictions on msg.sender.
     * @param from current owner of the token
     * @param to address to receive the ownership of the given token ID
     * @param tokenId uint256 ID of the token to be transferred
     */
    function _transferFrom(address from, address to, uint256 tokenId) internal {
        require(ownerOf(tokenId) == from);
        require(to != address(0));

        _clearApproval(tokenId);

        _ownedTokensCount[from].decrement();
        _ownedTokensCount[to].increment();

        _tokenOwner[tokenId] = to;

        emit Transfer(from, to, tokenId);
    }

    /**
     * @dev Internal function to invoke `onERC721Received` on a target address
     * The call is not executed if the target address is not a contract
     * @param from address representing the previous owner of the given token ID
     * @param to target address that will receive the tokens
     * @param tokenId uint256 ID of the token to be transferred
     * @param _data bytes optional data to send along with the call
     * @return bool whether the call correctly returned the expected magic value
     */
    function _checkOnERC721Received(address from, address to, uint256 tokenId, bytes memory _data)
        internal returns (bool)
    {
        if (!to.isContract()) {
            return true;
        }

        bytes4 retval = IERC721Receiver(to).onERC721Received(msg.sender, from, tokenId, _data);
        return (retval == _ERC721_RECEIVED);
    }

    /**
     * @dev Private function to clear current approval of a given token ID
     * @param tokenId uint256 ID of the token to be transferred
     */
    function _clearApproval(uint256 tokenId) private {
        if (_tokenApprovals[tokenId] != address(0)) {
            _tokenApprovals[tokenId] = address(0);
        }
    }
}

contract IERC721Enumerable is IERC721 {
    function totalSupply() public view returns (uint256);
    function tokenOfOwnerByIndex(address owner, uint256 index) public view returns (uint256 tokenId);

    function tokenByIndex(uint256 index) public view returns (uint256);
}

contract ERC721Holder is IERC721Receiver {
    function onERC721Received(address, address, uint256, bytes memory) public returns (bytes4) {
        return this.onERC721Received.selector;
    }
}

contract IERC721Metadata is IERC721 {
    function name() external view returns (string memory);
    function symbol() external view returns (string memory);
    function tokenURI(uint256 tokenId) external view returns (string memory);
}

contract ERC721Enumerable is ERC165, ERC721, IERC721Enumerable {
    // Mapping from owner to list of owned token IDs
    mapping(address => uint256[]) private _ownedTokens;

    // Mapping from token ID to index of the owner tokens list
    mapping(uint256 => uint256) private _ownedTokensIndex;

    // Array with all token ids, used for enumeration
    uint256[] private _allTokens;

    // Mapping from token id to position in the allTokens array
    mapping(uint256 => uint256) private _allTokensIndex;

    bytes4 private constant _INTERFACE_ID_ERC721_ENUMERABLE = 0x780e9d63;
    /*
     * 0x780e9d63 ===
     *     bytes4(keccak256('totalSupply()')) ^
     *     bytes4(keccak256('tokenOfOwnerByIndex(address,uint256)')) ^
     *     bytes4(keccak256('tokenByIndex(uint256)'))
     */

    /**
     * @dev Constructor function
     */
    constructor () public {
        // register the supported interface to conform to ERC721Enumerable via ERC165
        _registerInterface(_INTERFACE_ID_ERC721_ENUMERABLE);
    }

    /**
     * @dev Gets the token ID at a given index of the tokens list of the requested owner
     * @param owner address owning the tokens list to be accessed
     * @param index uint256 representing the index to be accessed of the requested tokens list
     * @return uint256 token ID at the given index of the tokens list owned by the requested address
     */
    function tokenOfOwnerByIndex(address owner, uint256 index) public view returns (uint256) {
        require(index < balanceOf(owner));
        return _ownedTokens[owner][index];
    }

    /**
     * @dev Gets the total amount of tokens stored by the contract
     * @return uint256 representing the total amount of tokens
     */
    function totalSupply() public view returns (uint256) {
        return _allTokens.length;
    }

    /**
     * @dev Gets the token ID at a given index of all the tokens in this contract
     * Reverts if the index is greater or equal to the total number of tokens
     * @param index uint256 representing the index to be accessed of the tokens list
     * @return uint256 token ID at the given index of the tokens list
     */
    function tokenByIndex(uint256 index) public view returns (uint256) {
        require(index < totalSupply());
        return _allTokens[index];
    }

    /**
     * @dev Internal function to transfer ownership of a given token ID to another address.
     * As opposed to transferFrom, this imposes no restrictions on msg.sender.
     * @param from current owner of the token
     * @param to address to receive the ownership of the given token ID
     * @param tokenId uint256 ID of the token to be transferred
     */
    function _transferFrom(address from, address to, uint256 tokenId) internal {
        super._transferFrom(from, to, tokenId);

        _removeTokenFromOwnerEnumeration(from, tokenId);

        _addTokenToOwnerEnumeration(to, tokenId);
    }

    /**
     * @dev Internal function to mint a new token
     * Reverts if the given token ID already exists
     * @param to address the beneficiary that will own the minted token
     * @param tokenId uint256 ID of the token to be minted
     */
    function _mint(address to, uint256 tokenId) internal {
        super._mint(to, tokenId);

        _addTokenToOwnerEnumeration(to, tokenId);

        _addTokenToAllTokensEnumeration(tokenId);
    }

    /**
     * @dev Internal function to burn a specific token
     * Reverts if the token does not exist
     * Deprecated, use _burn(uint256) instead
     * @param owner owner of the token to burn
     * @param tokenId uint256 ID of the token being burned
     */
    function _burn(address owner, uint256 tokenId) internal {
        super._burn(owner, tokenId);

        _removeTokenFromOwnerEnumeration(owner, tokenId);
        // Since tokenId will be deleted, we can clear its slot in _ownedTokensIndex to trigger a gas refund
        _ownedTokensIndex[tokenId] = 0;

        _removeTokenFromAllTokensEnumeration(tokenId);
    }

    /**
     * @dev Gets the list of token IDs of the requested owner
     * @param owner address owning the tokens
     * @return uint256[] List of token IDs owned by the requested address
     */
    function _tokensOfOwner(address owner) internal view returns (uint256[] storage) {
        return _ownedTokens[owner];
    }

    /**
     * @dev Private function to add a token to this extension's ownership-tracking data structures.
     * @param to address representing the new owner of the given token ID
     * @param tokenId uint256 ID of the token to be added to the tokens list of the given address
     */
    function _addTokenToOwnerEnumeration(address to, uint256 tokenId) private {
        _ownedTokensIndex[tokenId] = _ownedTokens[to].length;
        _ownedTokens[to].push(tokenId);
    }

    /**
     * @dev Private function to add a token to this extension's token tracking data structures.
     * @param tokenId uint256 ID of the token to be added to the tokens list
     */
    function _addTokenToAllTokensEnumeration(uint256 tokenId) private {
        _allTokensIndex[tokenId] = _allTokens.length;
        _allTokens.push(tokenId);
    }

    /**
     * @dev Private function to remove a token from this extension's ownership-tracking data structures. Note that
     * while the token is not assigned a new owner, the _ownedTokensIndex mapping is _not_ updated: this allows for
     * gas optimizations e.g. when performing a transfer operation (avoiding double writes).
     * This has O(1) time complexity, but alters the order of the _ownedTokens array.
     * @param from address representing the previous owner of the given token ID
     * @param tokenId uint256 ID of the token to be removed from the tokens list of the given address
     */
    function _removeTokenFromOwnerEnumeration(address from, uint256 tokenId) private {
        // To prevent a gap in from's tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = _ownedTokens[from].length.sub(1);
        uint256 tokenIndex = _ownedTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary
        if (tokenIndex != lastTokenIndex) {
            uint256 lastTokenId = _ownedTokens[from][lastTokenIndex];

            _ownedTokens[from][tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
            _ownedTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index
        }

        // This also deletes the contents at the last position of the array
        _ownedTokens[from].length--;

        // Note that _ownedTokensIndex[tokenId] hasn't been cleared: it still points to the old slot (now occupied by
        // lastTokenId, or just over the end of the array if the token was the last one).
    }

    /**
     * @dev Private function to remove a token from this extension's token tracking data structures.
     * This has O(1) time complexity, but alters the order of the _allTokens array.
     * @param tokenId uint256 ID of the token to be removed from the tokens list
     */
    function _removeTokenFromAllTokensEnumeration(uint256 tokenId) private {
        // To prevent a gap in the tokens array, we store the last token in the index of the token to delete, and
        // then delete the last slot (swap and pop).

        uint256 lastTokenIndex = _allTokens.length.sub(1);
        uint256 tokenIndex = _allTokensIndex[tokenId];

        // When the token to delete is the last token, the swap operation is unnecessary. However, since this occurs so
        // rarely (when the last minted token is burnt) that we still do the swap here to avoid the gas cost of adding
        // an 'if' statement (like in _removeTokenFromOwnerEnumeration)
        uint256 lastTokenId = _allTokens[lastTokenIndex];

        _allTokens[tokenIndex] = lastTokenId; // Move the last token to the slot of the to-delete token
        _allTokensIndex[lastTokenId] = tokenIndex; // Update the moved token's index

        // This also deletes the contents at the last position of the array
        _allTokens.length--;
        _allTokensIndex[tokenId] = 0;
    }
}

contract ERC721Metadata is ERC165, ERC721, IERC721Metadata {
    // Token name
    string private _name;

    // Token symbol
    string private _symbol;

    // Optional mapping for token URIs
    mapping(uint256 => string) private _tokenURIs;

    bytes4 private constant _INTERFACE_ID_ERC721_METADATA = 0x5b5e139f;
    /*
     * 0x5b5e139f ===
     *     bytes4(keccak256('name()')) ^
     *     bytes4(keccak256('symbol()')) ^
     *     bytes4(keccak256('tokenURI(uint256)'))
     */

    /**
     * @dev Constructor function
     */
    constructor (string memory name, string memory symbol) public {
        _name = name;
        _symbol = symbol;

        // register the supported interfaces to conform to ERC721 via ERC165
        _registerInterface(_INTERFACE_ID_ERC721_METADATA);
    }

    /**
     * @dev Gets the token name
     * @return string representing the token name
     */
    function name() external view returns (string memory) {
        return _name;
    }

    /**
     * @dev Gets the token symbol
     * @return string representing the token symbol
     */
    function symbol() external view returns (string memory) {
        return _symbol;
    }

    /**
     * @dev Returns an URI for a given token ID
     * Throws if the token ID does not exist. May return an empty string.
     * @param tokenId uint256 ID of the token to query
     */
    function tokenURI(uint256 tokenId) external view returns (string memory) {
        require(_exists(tokenId));
        return _tokenURIs[tokenId];
    }

    /**
     * @dev Internal function to set the token URI for a given token
     * Reverts if the token ID does not exist
     * @param tokenId uint256 ID of the token to set its URI
     * @param uri string URI to assign
     */
    function _setTokenURI(uint256 tokenId, string memory uri) internal {
        require(_exists(tokenId));
        _tokenURIs[tokenId] = uri;
    }

    /**
     * @dev Internal function to burn a specific token
     * Reverts if the token does not exist
     * Deprecated, use _burn(uint256) instead
     * @param owner owner of the token to burn
     * @param tokenId uint256 ID of the token being burned by the msg.sender
     */
    function _burn(address owner, uint256 tokenId) internal {
        super._burn(owner, tokenId);

        // Clear metadata (if any)
        if (bytes(_tokenURIs[tokenId]).length != 0) {
            delete _tokenURIs[tokenId];
        }
    }
}

contract ERC721Full is ERC721, ERC721Enumerable, ERC721Metadata {
    constructor (string memory name, string memory symbol) public ERC721Metadata(name, symbol) {
        // solhint-disable-previous-line no-empty-blocks
    }
}

contract Gener8tiveKBlocksERC721 is Ownable, ERC721Full, ERC721Holder, usingOraclize
{
    using SafeMath for uint8;
    using SafeMath for uint16;
    using Counters for Counters.Counter;

    // =======================================================
    // EVENTS
    // =======================================================
    event CauseBeneficiaryChanged(address indexed);
    event TokenUriUpdated(uint256 indexed tokenId);
    event FundsWithdrawn(address recipient, uint256 amount);

    // =======================================================
    // STATE
    // =======================================================
    Counters.Counter private tokenId;
    
    address payable public causeBeneficiary;
    
    uint256 public constant price = 275 finney;
    uint256 public constant feePercentage = 15;
    uint8 public constant maxSupply = 250;
    uint8 public constant creatorSupply = 50;
    
    // =======================================================
    // CONSTRUCTOR
    // =======================================================
    constructor (string memory _name, string memory _symbol, address payable _causeBeneficiary) public
        ERC721Full(_name, _symbol)
    {
        causeBeneficiary = _causeBeneficiary;
    }

    // =======================================================
    // STRURCTS & ENUMS
    // =======================================================
    struct Rectangle {
        uint8 index;
        uint8 x;
        uint8 y;
        uint8 width;
        uint8 height;
        uint16 color;
        uint16 saturation;
        uint16 colorRatio;
        uint16 transparency;
    }

     struct Circle {
         uint8 x;
         uint8 y;
         uint8 r;
         uint16 color;
     }

    // =======================================================
    // ADMIN
    // =======================================================
    function changeCauseBeneficiary(address payable newCauseBeneficiary)
        public
        onlyOwner
    {
        causeBeneficiary = newCauseBeneficiary;
        emit CauseBeneficiaryChanged(causeBeneficiary);
    }

    function updateTokenURI(uint256 _tokenId, string memory newTokenURI)
        public
        onlyOwner
    {
        super._setTokenURI(_tokenId, newTokenURI);
        emit TokenUriUpdated(_tokenId);
    }

    function withdrawFunds(address payable recipient, uint256 amount)
        public
        onlyOwner
    {
        recipient.transfer(amount);
        emit FundsWithdrawn(recipient, amount);
    }

    // =======================================================
    // UTILS & HELPERS
    // =======================================================
    function mul16(uint16 a, uint16 b) internal pure returns (uint16) {
        // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
        // benefit is lost if 'b' is also tested.
        // See: https://github.com/OpenZeppelin/openzeppelin-solidity/pull/522
        if (a == 0) {
            return 0;
        }

        uint16 c = a * b;
        require(c / a == b);

        return c;
    }

    function mul256(uint256 a, uint256 b) internal pure returns (uint256) {
        // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
        // benefit is lost if 'b' is also tested.
        // See: https://github.com/OpenZeppelin/openzeppelin-solidity/pull/522
        if (a == 0) {
            return 0;
        }

        uint256 c = a * b;
        require(c / a == b);

        return c;
    }

    function div16(uint16 a, uint16 b) internal pure returns (uint16) {
        // Solidity only automatically asserts when dividing by 0
        require(b > 0);
        uint16 c = a / b;
        // assert(a == b * c + a % b); // There is no case in which this doesn't hold

        return c;
    }

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

        return c;
    }

    // =======================================================
    // PUBLIC API
    // =======================================================
    function mint()
        external
        payable
    {
        // ensure the max supply has not been reached
        require(totalSupply() < maxSupply, "Max tokens issued");
        
        // the following block applicable for public minting
        if(msg.sender != owner()) {
            // ensure sufficient funds were sent
            require(msg.value >= price, "Insufficient ETH sent with transaction");

            // calculate system fees percentage
            uint256 fee = div256(mul256(feePercentage, msg.value), 100);

            // send to cause beneficiary (revert if no beneficiary is set)
            require(causeBeneficiary != address(0), "Cause Beneficiary not set");
            causeBeneficiary.transfer(msg.value - fee);
        }
        else {
            require(totalSupply() < creatorSupply, "Max number creator tokens already issued");
        }

        string memory tokenIdStr = uint2str(tokenId.current());

        super._mint(msg.sender, tokenId.current());
        super._setTokenURI(tokenId.current(), strConcat("https://api.gener8tive.io/kcompositions/tokens/metadata/", tokenIdStr));

        tokenId.increment();
    }

    function tokensOwned(address ownerAddress)
        public
        view
        returns (uint256[] memory)
    {
        return super._tokensOfOwner(ownerAddress);
    }

    function drawKComposistion(uint256 _tokenId)
        public
        view
        returns(bytes32 idKeccak, Rectangle[] memory rectangles, Circle memory circle)
    {
        if(!isOwner()) {
            // only allow viewing of composition data of tokens that have already been minted
            require(_exists(_tokenId), "Requested token does not exist yet");
        }

        idKeccak = keccak256(abi.encodePacked(_tokenId));
        
        uint8 numHashParts = uint8(idKeccak.length);
        
        rectangles = new Rectangle[](numHashParts / 3);
        
        uint8 pointer = 0;
        for(uint8 i = 0; i < rectangles.length; i++) {
            uint8 rectVal1 = uint8((idKeccak[pointer] >> 4) & 0x0f);
            uint8 rectVal2 = uint8(idKeccak[pointer] & 0x0f);
            uint8 rectVal3 = uint8((idKeccak[++pointer] >> 4) & 0x0f);
            uint8 rectVal4 = uint8(uint8(idKeccak[pointer] & 0x0f));
            uint8 rectVal5 = uint8((idKeccak[++pointer] >> 4) & 0x0f);
            uint8 rectVal6 = uint8(uint8(idKeccak[pointer] & 0x0f));

            //limit colorRatio to avoid whites
            uint16 crValue = div16(mul16(rectVal5, 100), 15);
            if(crValue > 90) {
                crValue = 90;
            }
            
            uint16 tmpSaturation = div16(mul16(rectVal3, 100), 15);

            Rectangle memory r = Rectangle({
                index: i,
                x: rectVal1,
                y: rectVal2,
                width: rectVal3,
                height: rectVal4,
                color: div16(mul16(rectVal1, 360), 15),
                saturation: tmpSaturation > 95 ? 95 : tmpSaturation,
                colorRatio: crValue,
                transparency: rectVal6 < 1 ? 1 : rectVal6
            });

            pointer++;

            rectangles[i] = r;
        }

        circle =  Circle({
            x: uint8((idKeccak[pointer] >> 4) & 0x0f),
            y: uint8(idKeccak[pointer] & 0x0f),
            r: uint8((idKeccak[++pointer] >> 4) & 0x0f),
            color: div16(mul16(uint8(idKeccak[pointer] & 0x0f), 360), 15)
        });
    }

    function getSupplyData(address ownerAddress)
        external
        view
        returns(
            uint8 supplyDataMaxSupply,
            uint8 supplyDataCreatorSupply,
            address supplyDataCauseBeneficiary,
            uint256 supplyDataPrice,
            uint256 supplyDataFeePercentage,
            uint256 supplyDataTotalSupply,
            uint256[] memory ownedTokens)
    {
        supplyDataCauseBeneficiary = causeBeneficiary;
        supplyDataPrice = price;
        supplyDataFeePercentage = feePercentage;
        supplyDataMaxSupply = maxSupply;
        supplyDataCreatorSupply = creatorSupply;
        supplyDataTotalSupply = totalSupply();
        ownedTokens = tokensOwned(ownerAddress);
    }

    function getTokenData(uint256 _tokenId)
        external
        view
        returns(
            bytes32 idKeccak,
            Rectangle[] memory rectangles,
            Circle memory circle,
            string memory tokenURI,
            address owner)
    {
        (idKeccak, rectangles, circle) = drawKComposistion(_tokenId);
        tokenURI = this.tokenURI(_tokenId);
        owner = ownerOf(_tokenId);
    }
}

Contract Security Audit

Contract ABI

[{"constant":true,"inputs":[],"name":"causeBeneficiary","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"interfaceId","type":"bytes4"}],"name":"supportsInterface","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"creatorSupply","outputs":[{"name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"name","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"tokenId","type":"uint256"}],"name":"getApproved","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"newCauseBeneficiary","type":"address"}],"name":"changeCauseBeneficiary","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"to","type":"address"},{"name":"tokenId","type":"uint256"}],"name":"approve","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[],"name":"mint","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":false,"inputs":[{"name":"","type":"address"},{"name":"","type":"address"},{"name":"","type":"uint256"},{"name":"","type":"bytes"}],"name":"onERC721Received","outputs":[{"name":"","type":"bytes4"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"totalSupply","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_tokenId","type":"uint256"},{"name":"newTokenURI","type":"string"}],"name":"updateTokenURI","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"ownerAddress","type":"address"}],"name":"tokensOwned","outputs":[{"name":"","type":"uint256[]"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"from","type":"address"},{"name":"to","type":"address"},{"name":"tokenId","type":"uint256"}],"name":"transferFrom","outputs":[],"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":"owner","type":"address"},{"name":"index","type":"uint256"}],"name":"tokenOfOwnerByIndex","outputs":[{"name":"","type":"uint256"}],"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":false,"inputs":[{"name":"from","type":"address"},{"name":"to","type":"address"},{"name":"tokenId","type":"uint256"}],"name":"safeTransferFrom","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"index","type":"uint256"}],"name":"tokenByIndex","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"tokenId","type":"uint256"}],"name":"ownerOf","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"owner","type":"address"}],"name":"balanceOf","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[],"name":"renounceOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"isOwner","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"ownerAddress","type":"address"}],"name":"getSupplyData","outputs":[{"name":"supplyDataMaxSupply","type":"uint8"},{"name":"supplyDataCreatorSupply","type":"uint8"},{"name":"supplyDataCauseBeneficiary","type":"address"},{"name":"supplyDataPrice","type":"uint256"},{"name":"supplyDataFeePercentage","type":"uint256"},{"name":"supplyDataTotalSupply","type":"uint256"},{"name":"ownedTokens","type":"uint256[]"}],"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":"feePercentage","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"price","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"to","type":"address"},{"name":"approved","type":"bool"}],"name":"setApprovalForAll","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_tokenId","type":"uint256"}],"name":"getTokenData","outputs":[{"name":"idKeccak","type":"bytes32"},{"components":[{"name":"index","type":"uint8"},{"name":"x","type":"uint8"},{"name":"y","type":"uint8"},{"name":"width","type":"uint8"},{"name":"height","type":"uint8"},{"name":"color","type":"uint16"},{"name":"saturation","type":"uint16"},{"name":"colorRatio","type":"uint16"},{"name":"transparency","type":"uint16"}],"name":"rectangles","type":"tuple[]"},{"components":[{"name":"x","type":"uint8"},{"name":"y","type":"uint8"},{"name":"r","type":"uint8"},{"name":"color","type":"uint16"}],"name":"circle","type":"tuple"},{"name":"tokenURI","type":"string"},{"name":"owner","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"from","type":"address"},{"name":"to","type":"address"},{"name":"tokenId","type":"uint256"},{"name":"_data","type":"bytes"}],"name":"safeTransferFrom","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"recipient","type":"address"},{"name":"amount","type":"uint256"}],"name":"withdrawFunds","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"_tokenId","type":"uint256"}],"name":"drawKComposistion","outputs":[{"name":"idKeccak","type":"bytes32"},{"components":[{"name":"index","type":"uint8"},{"name":"x","type":"uint8"},{"name":"y","type":"uint8"},{"name":"width","type":"uint8"},{"name":"height","type":"uint8"},{"name":"color","type":"uint16"},{"name":"saturation","type":"uint16"},{"name":"colorRatio","type":"uint16"},{"name":"transparency","type":"uint16"}],"name":"rectangles","type":"tuple[]"},{"components":[{"name":"x","type":"uint8"},{"name":"y","type":"uint8"},{"name":"r","type":"uint8"},{"name":"color","type":"uint16"}],"name":"circle","type":"tuple"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"tokenId","type":"uint256"}],"name":"tokenURI","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"maxSupply","outputs":[{"name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"owner","type":"address"},{"name":"operator","type":"address"}],"name":"isApprovedForAll","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"inputs":[{"name":"_name","type":"string"},{"name":"_symbol","type":"string"},{"name":"_causeBeneficiary","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"name":"","type":"address"}],"name":"CauseBeneficiaryChanged","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"tokenId","type":"uint256"}],"name":"TokenUriUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"recipient","type":"address"},{"indexed":false,"name":"amount","type":"uint256"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"from","type":"address"},{"indexed":true,"name":"to","type":"address"},{"indexed":true,"name":"tokenId","type":"uint256"}],"name":"Transfer","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"owner","type":"address"},{"indexed":true,"name":"approved","type":"address"},{"indexed":true,"name":"tokenId","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"owner","type":"address"},{"indexed":true,"name":"operator","type":"address"},{"indexed":false,"name":"approved","type":"bool"}],"name":"ApprovalForAll","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"previousOwner","type":"address"},{"indexed":true,"name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"}]

60806040523480156200001157600080fd5b5060405162004a9838038062004a9883398101806040526200003791908101906200044c565b82828181336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3620001346301ffc9a77c0100000000000000000000000000000000000000000000000000000000026200026b640100000000026401000000009004565b620001716380ac58cd7c0100000000000000000000000000000000000000000000000000000000026200026b640100000000026401000000009004565b620001ae63780e9d637c0100000000000000000000000000000000000000000000000000000000026200026b640100000000026401000000009004565b81600a9080519060200190620001c692919062000329565b5080600b9080519060200190620001df92919062000329565b506200021d635b5e139f7c0100000000000000000000000000000000000000000000000000000000026200026b640100000000026401000000009004565b5050505080601360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050505062000599565b63ffffffff7c010000000000000000000000000000000000000000000000000000000002817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614151515620002bd57600080fd5b6001806000837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200190815260200160002060006101000a81548160ff02191690831515021790555050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106200036c57805160ff19168380011785556200039d565b828001600101855582156200039d579182015b828111156200039c5782518255916020019190600101906200037f565b5b509050620003ac9190620003b0565b5090565b620003d591905b80821115620003d1576000816000905550600101620003b7565b5090565b90565b6000620003e682516200054f565b905092915050565b600082601f83011215156200040257600080fd5b815162000419620004138262000502565b620004d4565b915080825260208301602083018583830111156200043657600080fd5b6200044383828462000563565b50505092915050565b6000806000606084860312156200046257600080fd5b600084015167ffffffffffffffff8111156200047d57600080fd5b6200048b86828701620003ee565b935050602084015167ffffffffffffffff811115620004a957600080fd5b620004b786828701620003ee565b9250506040620004ca86828701620003d8565b9150509250925092565b6000604051905081810181811067ffffffffffffffff82111715620004f857600080fd5b8060405250919050565b600067ffffffffffffffff8211156200051a57600080fd5b601f19601f8301169050602081019050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006200055c826200052f565b9050919050565b60005b838110156200058357808201518184015260208101905062000566565b8381111562000593576000848401525b50505050565b6144ef80620005a96000396000f3fe60806040526004361061022b576000357c0100000000000000000000000000000000000000000000000000000000900480636352211e11610135578063a22cb465116100bd578063c38f8c291161008c578063c38f8c29146107da578063c87b56dd14610819578063d5abeb0114610856578063e985e9c514610881578063f2fde38b146108be5761022b565b8063a22cb4651461071e578063b09afec114610747578063b88d4fde14610788578063c1075329146107b15761022b565b80638f32d59b116101045780638f32d59b1461062f57806392dde1921461065a57806395d89b411461069d578063a001ecdd146106c8578063a035b1fe146106f35761022b565b80636352211e1461057357806370a08231146105b0578063715018a6146105ed5780638da5cb5b146106045761022b565b806318160ddd116101b857806327dc297e1161018757806327dc297e1461047e5780632f745c59146104a757806338bbfa50146104e457806342842e0e1461050d5780634f6ccce7146105365761022b565b806318160ddd146103c457806318e97fd1146103ef57806321cda7901461041857806323b872dd146104555761022b565b8063081812fc116101ff578063081812fc146102ee578063093e10731461032b578063095ea7b3146103545780631249c58b1461037d578063150b7a02146103875761022b565b8062ff44421461023057806301ffc9a71461025b578063059caad31461029857806306fdde03146102c3575b600080fd5b34801561023c57600080fd5b506102456108e7565b6040516102529190613efe565b60405180910390f35b34801561026757600080fd5b50610282600480360361027d9190810190613998565b61090d565b60405161028f9190613fb0565b60405180910390f35b3480156102a457600080fd5b506102ad610975565b6040516102ba9190614163565b60405180910390f35b3480156102cf57600080fd5b506102d861097a565b6040516102e59190614086565b60405180910390f35b3480156102fa57600080fd5b5061031560048036036103109190810190613a2b565b610a1c565b6040516103229190613ee3565b60405180910390f35b34801561033757600080fd5b50610352600480360361034d91908101906136e2565b610a6d565b005b34801561036057600080fd5b5061037b60048036036103769190810190613889565b610b29565b005b610385610c6e565b005b34801561039357600080fd5b506103ae60048036036103a991908101906137d2565b610f1f565b6040516103bb919061406b565b60405180910390f35b3480156103d057600080fd5b506103d9610f4f565b6040516103e69190614148565b60405180910390f35b3480156103fb57600080fd5b5061041660048036036104119190810190613a54565b610f5c565b005b34801561042457600080fd5b5061043f600480360361043a91908101906136b9565b610faa565b60405161044c9190613f8e565b60405180910390f35b34801561046157600080fd5b5061047c60048036036104779190810190613783565b61100b565b005b34801561048a57600080fd5b506104a560048036036104a091908101906138c5565b611030565b005b3480156104b357600080fd5b506104ce60048036036104c99190810190613889565b611073565b6040516104db9190614148565b60405180910390f35b3480156104f057600080fd5b5061050b60048036036105069190810190613919565b6110ea565b005b34801561051957600080fd5b50610534600480360361052f9190810190613783565b6110ef565b005b34801561054257600080fd5b5061055d60048036036105589190810190613a2b565b611110565b60405161056a9190614148565b60405180910390f35b34801561057f57600080fd5b5061059a60048036036105959190810190613a2b565b611148565b6040516105a79190613ee3565b60405180910390f35b3480156105bc57600080fd5b506105d760048036036105d291908101906136b9565b6111c6565b6040516105e49190614148565b60405180910390f35b3480156105f957600080fd5b50610602611251565b005b34801561061057600080fd5b50610619611323565b6040516106269190613ee3565b60405180910390f35b34801561063b57600080fd5b5061064461134c565b6040516106519190613fb0565b60405180910390f35b34801561066657600080fd5b50610681600480360361067c91908101906136b9565b6113a3565b604051610694979695949392919061417e565b60405180910390f35b3480156106a957600080fd5b506106b261140a565b6040516106bf9190614086565b60405180910390f35b3480156106d457600080fd5b506106dd6114ac565b6040516106ea9190614148565b60405180910390f35b3480156106ff57600080fd5b506107086114b1565b6040516107159190614148565b60405180910390f35b34801561072a57600080fd5b506107456004803603610740919081019061384d565b6114bd565b005b34801561075357600080fd5b5061076e60048036036107699190810190613a2b565b6115f5565b60405161077f959493929190614009565b60405180910390f35b34801561079457600080fd5b506107af60048036036107aa91908101906137d2565b6116da565b005b3480156107bd57600080fd5b506107d860048036036107d3919081019061370b565b611702565b005b3480156107e657600080fd5b5061080160048036036107fc9190810190613a2b565b611799565b60405161081093929190613fcb565b60405180910390f35b34801561082557600080fd5b50610840600480360361083b9190810190613a2b565b611ffd565b60405161084d9190614086565b60405180910390f35b34801561086257600080fd5b5061086b6120c6565b6040516108789190614163565b60405180910390f35b34801561088d57600080fd5b506108a860048036036108a39190810190613747565b6120cb565b6040516108b59190613fb0565b60405180910390f35b3480156108ca57600080fd5b506108e560048036036108e091908101906136b9565b61215f565b005b601360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600060016000837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200190815260200160002060009054906101000a900460ff169050919050565b603281565b6060600a8054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610a125780601f106109e757610100808354040283529160200191610a12565b820191906000526020600020905b8154815290600101906020018083116109f557829003601f168201915b5050505050905090565b6000610a278261217e565b1515610a3257600080fd5b6003600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b610a7561134c565b1515610a8057600080fd5b80601360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550601360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167fc107e672c8fedf7b9c82f11edfe1b1095102ff92cbd17ac360fc508c1ec3de1a60405160405180910390a250565b6000610b3482611148565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614151515610b7157600080fd5b8073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480610bb15750610bb081336120cb565b5b1515610bbc57600080fd5b826003600084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550818373ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a4505050565b60fa60ff16610c7b610f4f565b101515610cbd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610cb490614108565b60405180910390fd5b610cc5611323565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515610e64576703d0ff0b013b80003410151515610d46576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d3d906140c8565b60405180910390fd5b6000610d5d610d56600f346121f0565b606461222e565b9050600073ffffffffffffffffffffffffffffffffffffffff16601360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614151515610df3576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610dea906140e8565b60405180910390fd5b601360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166108fc8234039081150290604051600060405180830381858888f19350505050158015610e5d573d6000803e3d6000fd5b5050610eb4565b603260ff16610e71610f4f565b101515610eb3576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610eaa906140a8565b60405180910390fd5b5b6060610ec8610ec36012612258565b612266565b9050610edd33610ed86012612258565b6123bf565b610f12610eea6012612258565b610f0d6060604051908101604052806038815260200161447e60389139846123e0565b612427565b610f1c6012612467565b50565b600063150b7a027c0100000000000000000000000000000000000000000000000000000000029050949350505050565b6000600880549050905090565b610f6461134c565b1515610f6f57600080fd5b610f798282612427565b817fb3cbb6e549295716426a3c3b711cfeda7303d2c3cba225a8fb69cb06bdec178560405160405180910390a25050565b6060610fb58261247d565b805480602002602001604051908101604052809291908181526020018280548015610fff57602002820191906000526020600020905b815481526020019060010190808311610feb575b50505050509050919050565b61101533826124c5565b151561102057600080fd5b61102b83838361255a565b505050565b61106f828260006040519080825280601f01601f1916602001820160405280156110695781602001600182028038833980820191505090505b506110ea565b5050565b600061107e836111c6565b8210151561108b57600080fd5b600660008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020828154811015156110d757fe5b9060005260206000200154905092915050565b505050565b61110b83838360206040519081016040528060008152506116da565b505050565b600061111a610f4f565b8210151561112757600080fd5b60088281548110151561113657fe5b90600052602060002001549050919050565b6000806002600084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141515156111bd57600080fd5b80915050919050565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415151561120357600080fd5b61124a600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020612258565b9050919050565b61125961134c565b151561126457600080fd5b600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360008060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614905090565b6000806000806000806060601360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1694506703d0ff0b013b80009350600f925060fa9650603295506113f2610f4f565b91506113fd88610faa565b9050919395979092949650565b6060600b8054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156114a25780601f10611477576101008083540402835291602001916114a2565b820191906000526020600020905b81548152906001019060200180831161148557829003601f168201915b5050505050905090565b600f81565b6703d0ff0b013b800081565b3373ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141515156114f857600080fd5b80600560003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31836040516115e99190613fb0565b60405180910390a35050565b6000606061160161334c565b6060600061160e86611799565b8095508196508297505050503073ffffffffffffffffffffffffffffffffffffffff1663c87b56dd876040518263ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040161166f9190614148565b60006040518083038186803b15801561168757600080fd5b505afa15801561169b573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052506116c491908101906139ea565b91506116cf86611148565b905091939590929450565b6116e584848461100b565b6116f18484848461257e565b15156116fc57600080fd5b50505050565b61170a61134c565b151561171557600080fd5b8173ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f1935050505015801561175b573d6000803e3d6000fd5b507feaff4b37086828766ad3268786972c0cd24259d4c87a80f9d3963a3c3d999b0d828260405161178d929190613f65565b60405180910390a15050565b600060606117a561334c565b6117ad61134c565b15156117fe576117bc8461217e565b15156117fd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117f490614128565b60405180910390fd5b5b836040516020018082815260200191505060405160208183030381529060405280519060200120925060006020905060038160ff1681151561183c57fe5b0460ff1660405190808252806020026020018201604052801561187957816020015b611866613382565b81526020019060019003908161185e5790505b509250600080905060008090505b84518160ff161015611d5c576000600f7f0100000000000000000000000000000000000000000000000000000000000000026004888560ff166020811015156118cc57fe5b1a7f0100000000000000000000000000000000000000000000000000000000000000027effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908060020a8204915050167f0100000000000000000000000000000000000000000000000000000000000000900490506000600f7f010000000000000000000000000000000000000000000000000000000000000002888560ff1660208110151561197857fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002167f0100000000000000000000000000000000000000000000000000000000000000900490506000600f7f01000000000000000000000000000000000000000000000000000000000000000260048a8760010197508760ff16602081101515611a0057fe5b1a7f0100000000000000000000000000000000000000000000000000000000000000027effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908060020a8204915050167f0100000000000000000000000000000000000000000000000000000000000000900490506000600f7f0100000000000000000000000000000000000000000000000000000000000000028a8760ff16602081101515611aac57fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002167f0100000000000000000000000000000000000000000000000000000000000000900490506000600f7f01000000000000000000000000000000000000000000000000000000000000000260048c8960010199508960ff16602081101515611b3457fe5b1a7f0100000000000000000000000000000000000000000000000000000000000000027effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908060020a8204915050167f0100000000000000000000000000000000000000000000000000000000000000900490506000600f7f0100000000000000000000000000000000000000000000000000000000000000028c8960ff16602081101515611be057fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002167f0100000000000000000000000000000000000000000000000000000000000000900490506000611c43611c3c8460ff1660646126cf565b600f612721565b9050605a8161ffff161115611c5757605a90505b6000611c71611c6a8760ff1660646126cf565b600f612721565b9050611c7b6133ee565b610120604051908101604052808b60ff1681526020018a60ff1681526020018960ff1681526020018860ff1681526020018760ff168152602001611cce611cc78c60ff166101686126cf565b600f612721565b61ffff168152602001605f8461ffff1611611ce95783611cec565b605f5b61ffff1681526020018461ffff16815260200160018660ff1610611d105785611d13565b60015b60ff1661ffff1681525090508a806001019b5050808e8b60ff16815181101515611d3957fe5b906020019060200201819052505050505050505050508080600101915050611887565b50608060405190810160405280600f7f0100000000000000000000000000000000000000000000000000000000000000026004888560ff16602081101515611da057fe5b1a7f0100000000000000000000000000000000000000000000000000000000000000027effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908060020a8204915050167f0100000000000000000000000000000000000000000000000000000000000000900460ff168152602001600f7f010000000000000000000000000000000000000000000000000000000000000002878460ff16602081101515611e5057fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002167f0100000000000000000000000000000000000000000000000000000000000000900460ff168152602001600f7f0100000000000000000000000000000000000000000000000000000000000000026004888560010195508560ff16602081101515611edc57fe5b1a7f0100000000000000000000000000000000000000000000000000000000000000027effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908060020a8204915050167f0100000000000000000000000000000000000000000000000000000000000000900460ff168152602001611feb611fe4600f7f010000000000000000000000000000000000000000000000000000000000000002898660ff16602081101515611f9257fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002167f0100000000000000000000000000000000000000000000000000000000000000900460ff166101686126cf565b600f612721565b61ffff16815250925050509193909250565b60606120088261217e565b151561201357600080fd5b600c60008381526020019081526020016000208054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156120ba5780601f1061208f576101008083540402835291602001916120ba565b820191906000526020600020905b81548152906001019060200180831161209d57829003601f168201915b50505050509050919050565b60fa81565b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b61216761134c565b151561217257600080fd5b61217b81612757565b50565b6000806002600084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415915050919050565b6000808314156122035760009050612228565b6000828402905082848281151561221657fe5b0414151561222357600080fd5b809150505b92915050565b6000808211151561223e57600080fd5b6000828481151561224b57fe5b0490508091505092915050565b600081600001549050919050565b606060008214156122ae576040805190810160405280600181526020017f300000000000000000000000000000000000000000000000000000000000000081525090506123ba565b600082905060005b6000821415156122dc578080600101915050600a828115156122d457fe5b0491506122b6565b6060816040519080825280601f01601f1916602001820160405280156123115781602001600182028038833980820191505090505b50905060006001830390505b6000861415156123b257600a8681151561233357fe5b066030017f01000000000000000000000000000000000000000000000000000000000000000282828060019003935081518110151561236e57fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600a868115156123aa57fe5b04955061231d565b819450505050505b919050565b6123c98282612851565b6123d3828261299b565b6123dc81612a62565b5050565b606061241f8383602060405190810160405280600081525060206040519081016040528060008152506020604051908101604052806000815250612aae565b905092915050565b6124308261217e565b151561243b57600080fd5b80600c6000848152602001908152602001600020908051906020019061246292919061345a565b505050565b6001816000016000828254019250508190555050565b6000600660008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050919050565b6000806124d183611148565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16148061254057508373ffffffffffffffffffffffffffffffffffffffff1661252884610a1c565b73ffffffffffffffffffffffffffffffffffffffff16145b80612551575061255081856120cb565b5b91505092915050565b612565838383612ec9565b61256f8382613090565b612579828261299b565b505050565b600061259f8473ffffffffffffffffffffffffffffffffffffffff16613234565b15156125ae57600190506126c7565b60008473ffffffffffffffffffffffffffffffffffffffff1663150b7a02338887876040518563ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040161260b9493929190613f19565b602060405180830381600087803b15801561262557600080fd5b505af1158015612639573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061265d91908101906139c1565b905063150b7a027c0100000000000000000000000000000000000000000000000000000000027bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149150505b949350505050565b6000808361ffff1614156126e6576000905061271b565b600082840290508261ffff168461ffff168261ffff1681151561270557fe5b0461ffff1614151561271657600080fd5b809150505b92915050565b6000808261ffff1611151561273557600080fd5b60008261ffff168461ffff1681151561274a57fe5b0490508091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415151561279357600080fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415151561288d57600080fd5b6128968161217e565b1515156128a257600080fd5b816002600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555061293b600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020612467565b808273ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a45050565b600660008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805490506007600083815260200190815260200160002081905550600660008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190806001815401808255809150509060018203906000526020600020016000909192909190915055505050565b6008805490506009600083815260200190815260200160002081905550600881908060018154018082558091505090600182039060005260206000200160009091929091909150555050565b6060808690506060869050606086905060608690506060869050606081518351855187518951010101016040519080825280601f01601f191660200182016040528015612b0a5781602001600182028038833980820191505090505b509050606081905060008090506000809050600090505b8851811015612bd4578881815181101515612b3857fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f0100000000000000000000000000000000000000000000000000000000000000028383806001019450815181101515612b9757fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080600101915050612b21565b600090505b8751811015612c8c578781815181101515612bf057fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f0100000000000000000000000000000000000000000000000000000000000000028383806001019450815181101515612c4f57fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080600101915050612bd9565b600090505b8651811015612d44578681815181101515612ca857fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f0100000000000000000000000000000000000000000000000000000000000000028383806001019450815181101515612d0757fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080600101915050612c91565b600090505b8551811015612dfc578581815181101515612d6057fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f0100000000000000000000000000000000000000000000000000000000000000028383806001019450815181101515612dbf57fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080600101915050612d49565b600090505b8451811015612eb4578481815181101515612e1857fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f0100000000000000000000000000000000000000000000000000000000000000028383806001019450815181101515612e7757fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080600101915050612e01565b82995050505050505050505095945050505050565b8273ffffffffffffffffffffffffffffffffffffffff16612ee982611148565b73ffffffffffffffffffffffffffffffffffffffff16141515612f0b57600080fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614151515612f4757600080fd5b612f5081613247565b612f97600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020613307565b612fde600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020612467565b816002600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4505050565b60006130e86001600660008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054905061332a90919063ffffffff16565b905060006007600084815260200190815260200160002054905081811415156131db576000600660008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208381548110151561315957fe5b9060005260206000200154905080600660008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020838154811015156131b357fe5b9060005260206000200181905550816007600083815260200190815260200160002081905550505b600660008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080548091906001900361322d91906134da565b5050505050565b600080823b905060008111915050919050565b600073ffffffffffffffffffffffffffffffffffffffff166003600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415156133045760006003600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505b50565b61331f6001826000015461332a90919063ffffffff16565b816000018190555050565b600082821115151561333b57600080fd5b600082840390508091505092915050565b608060405190810160405280600060ff168152602001600060ff168152602001600060ff168152602001600061ffff1681525090565b61012060405190810160405280600060ff168152602001600060ff168152602001600060ff168152602001600060ff168152602001600060ff168152602001600061ffff168152602001600061ffff168152602001600061ffff168152602001600061ffff1681525090565b61012060405190810160405280600060ff168152602001600060ff168152602001600060ff168152602001600060ff168152602001600060ff168152602001600061ffff168152602001600061ffff168152602001600061ffff168152602001600061ffff1681525090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1061349b57805160ff19168380011785556134c9565b828001600101855582156134c9579182015b828111156134c85782518255916020019190600101906134ad565b5b5090506134d69190613506565b5090565b815481835581811115613501578183600052602060002091820191016135009190613506565b5b505050565b61352891905b8082111561352457600081600090555060010161350c565b5090565b90565b60006135378235614384565b905092915050565b600061354b8235614396565b905092915050565b600061355f82356143a8565b905092915050565b600061357382356143b4565b905092915050565b600061358782356143be565b905092915050565b600061359b82516143be565b905092915050565b600082601f83011215156135b657600080fd5b81356135c96135c482614221565b6141f4565b915080825260208301602083018583830111156135e557600080fd5b6135f083828461442a565b50505092915050565b600082601f830112151561360c57600080fd5b813561361f61361a8261424d565b6141f4565b9150808252602083016020830185838301111561363b57600080fd5b61364683828461442a565b50505092915050565b600082601f830112151561366257600080fd5b81516136756136708261424d565b6141f4565b9150808252602083016020830185838301111561369157600080fd5b61369c838284614439565b50505092915050565b60006136b182356143ea565b905092915050565b6000602082840312156136cb57600080fd5b60006136d98482850161352b565b91505092915050565b6000602082840312156136f457600080fd5b60006137028482850161353f565b91505092915050565b6000806040838503121561371e57600080fd5b600061372c8582860161353f565b925050602061373d858286016136a5565b9150509250929050565b6000806040838503121561375a57600080fd5b60006137688582860161352b565b92505060206137798582860161352b565b9150509250929050565b60008060006060848603121561379857600080fd5b60006137a68682870161352b565b93505060206137b78682870161352b565b92505060406137c8868287016136a5565b9150509250925092565b600080600080608085870312156137e857600080fd5b60006137f68782880161352b565b94505060206138078782880161352b565b9350506040613818878288016136a5565b925050606085013567ffffffffffffffff81111561383557600080fd5b613841878288016135a3565b91505092959194509250565b6000806040838503121561386057600080fd5b600061386e8582860161352b565b925050602061387f85828601613553565b9150509250929050565b6000806040838503121561389c57600080fd5b60006138aa8582860161352b565b92505060206138bb858286016136a5565b9150509250929050565b600080604083850312156138d857600080fd5b60006138e685828601613567565b925050602083013567ffffffffffffffff81111561390357600080fd5b61390f858286016135f9565b9150509250929050565b60008060006060848603121561392e57600080fd5b600061393c86828701613567565b935050602084013567ffffffffffffffff81111561395957600080fd5b613965868287016135f9565b925050604084013567ffffffffffffffff81111561398257600080fd5b61398e868287016135a3565b9150509250925092565b6000602082840312156139aa57600080fd5b60006139b88482850161357b565b91505092915050565b6000602082840312156139d357600080fd5b60006139e18482850161358f565b91505092915050565b6000602082840312156139fc57600080fd5b600082015167ffffffffffffffff811115613a1657600080fd5b613a228482850161364f565b91505092915050565b600060208284031215613a3d57600080fd5b6000613a4b848285016136a5565b91505092915050565b60008060408385031215613a6757600080fd5b6000613a75858286016136a5565b925050602083013567ffffffffffffffff811115613a9257600080fd5b613a9e858286016135f9565b9150509250929050565b613ab1816143f4565b82525050565b613ac0816142eb565b82525050565b613acf816142d9565b82525050565b6000613ae082614293565b808452602084019350613af283614279565b60005b82811015613b2557613b08868351613dff565b613b11826142bf565b915061012086019550600181019050613af5565b50849250505092915050565b6000613b3c8261429e565b808452602084019350613b4e83614286565b60005b82811015613b8057613b64868351613ec5565b613b6d826142cc565b9150602086019550600181019050613b51565b50849250505092915050565b613b95816142fd565b82525050565b613ba481614309565b82525050565b613bb381614313565b82525050565b6000613bc4826142a9565b808452613bd8816020860160208601614439565b613be18161446c565b602085010191505092915050565b6000613bfa826142b4565b808452613c0e816020860160208601614439565b613c178161446c565b602085010191505092915050565b6000602882527f4d6178206e756d6265722063726561746f7220746f6b656e7320616c7265616460208301527f79206973737565640000000000000000000000000000000000000000000000006040830152606082019050919050565b6000602682527f496e73756666696369656e74204554482073656e742077697468207472616e7360208301527f616374696f6e00000000000000000000000000000000000000000000000000006040830152606082019050919050565b6000601982527f43617573652042656e6566696369617279206e6f7420736574000000000000006020830152604082019050919050565b6000601182527f4d617820746f6b656e73206973737565640000000000000000000000000000006020830152604082019050919050565b6000602282527f52657175657374656420746f6b656e20646f6573206e6f74206578697374207960208301527f65740000000000000000000000000000000000000000000000000000000000006040830152606082019050919050565b608082016000820151613dc06000850182613ed4565b506020820151613dd36020850182613ed4565b506040820151613de66040850182613ed4565b506060820151613df96060850182613eb6565b50505050565b61012082016000820151613e166000850182613ed4565b506020820151613e296020850182613ed4565b506040820151613e3c6040850182613ed4565b506060820151613e4f6060850182613ed4565b506080820151613e626080850182613ed4565b5060a0820151613e7560a0850182613eb6565b5060c0820151613e8860c0850182613eb6565b5060e0820151613e9b60e0850182613eb6565b50610100820151613eb0610100850182613eb6565b50505050565b613ebf8161433f565b82525050565b613ece8161436d565b82525050565b613edd81614377565b82525050565b6000602082019050613ef86000830184613ac6565b92915050565b6000602082019050613f136000830184613ab7565b92915050565b6000608082019050613f2e6000830187613aa8565b613f3b6020830186613ac6565b613f486040830185613ec5565b8181036060830152613f5a8184613bb9565b905095945050505050565b6000604082019050613f7a6000830185613aa8565b613f876020830184613ec5565b9392505050565b60006020820190508181036000830152613fa88184613b31565b905092915050565b6000602082019050613fc56000830184613b8c565b92915050565b600060c082019050613fe06000830186613b9b565b8181036020830152613ff28185613ad5565b90506140016040830184613daa565b949350505050565b60006101008201905061401f6000830188613b9b565b81810360208301526140318187613ad5565b90506140406040830186613daa565b81810360c08301526140528185613bef565b905061406160e0830184613ac6565b9695505050505050565b60006020820190506140806000830184613baa565b92915050565b600060208201905081810360008301526140a08184613bef565b905092915050565b600060208201905081810360008301526140c181613c25565b9050919050565b600060208201905081810360008301526140e181613c82565b9050919050565b6000602082019050818103600083015261410181613cdf565b9050919050565b6000602082019050818103600083015261412181613d16565b9050919050565b6000602082019050818103600083015261414181613d4d565b9050919050565b600060208201905061415d6000830184613ec5565b92915050565b60006020820190506141786000830184613ed4565b92915050565b600060e082019050614193600083018a613ed4565b6141a06020830189613ed4565b6141ad6040830188613ac6565b6141ba6060830187613ec5565b6141c76080830186613ec5565b6141d460a0830185613ec5565b81810360c08301526141e68184613b31565b905098975050505050505050565b6000604051905081810181811067ffffffffffffffff8211171561421757600080fd5b8060405250919050565b600067ffffffffffffffff82111561423857600080fd5b601f19601f8301169050602081019050919050565b600067ffffffffffffffff82111561426457600080fd5b601f19601f8301169050602081019050919050565b6000602082019050919050565b6000602082019050919050565b600081519050919050565b600081519050919050565b600081519050919050565b600081519050919050565b6000602082019050919050565b6000602082019050919050565b60006142e48261434d565b9050919050565b60006142f68261434d565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600061ffff82169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b600060ff82169050919050565b600061438f8261434d565b9050919050565b60006143a18261434d565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b6000819050919050565b60006143ff82614406565b9050919050565b600061441182614418565b9050919050565b60006144238261434d565b9050919050565b82818337600083830152505050565b60005b8381101561445757808201518184015260208101905061443c565b83811115614466576000848401525b50505050565b6000601f19601f830116905091905056fe68747470733a2f2f6170692e67656e657238746976652e696f2f6b636f6d706f736974696f6e732f746f6b656e732f6d657461646174612fa265627a7a7230582007c1d574a49a12a38c33f71ecb0b2480a604b289ae86922c36d36dbfc30a69ba6c6578706572696d656e74616cf50037000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000c7464dbca260a8faf033460622b23467df5aea42000000000000000000000000000000000000000000000000000000000000001947656e65723874697665204b2d436f6d706f736974696f6e7300000000000000000000000000000000000000000000000000000000000000000000000000000447ea9ea200000000000000000000000000000000000000000000000000000000

Deployed Bytecode

0x60806040526004361061022b576000357c0100000000000000000000000000000000000000000000000000000000900480636352211e11610135578063a22cb465116100bd578063c38f8c291161008c578063c38f8c29146107da578063c87b56dd14610819578063d5abeb0114610856578063e985e9c514610881578063f2fde38b146108be5761022b565b8063a22cb4651461071e578063b09afec114610747578063b88d4fde14610788578063c1075329146107b15761022b565b80638f32d59b116101045780638f32d59b1461062f57806392dde1921461065a57806395d89b411461069d578063a001ecdd146106c8578063a035b1fe146106f35761022b565b80636352211e1461057357806370a08231146105b0578063715018a6146105ed5780638da5cb5b146106045761022b565b806318160ddd116101b857806327dc297e1161018757806327dc297e1461047e5780632f745c59146104a757806338bbfa50146104e457806342842e0e1461050d5780634f6ccce7146105365761022b565b806318160ddd146103c457806318e97fd1146103ef57806321cda7901461041857806323b872dd146104555761022b565b8063081812fc116101ff578063081812fc146102ee578063093e10731461032b578063095ea7b3146103545780631249c58b1461037d578063150b7a02146103875761022b565b8062ff44421461023057806301ffc9a71461025b578063059caad31461029857806306fdde03146102c3575b600080fd5b34801561023c57600080fd5b506102456108e7565b6040516102529190613efe565b60405180910390f35b34801561026757600080fd5b50610282600480360361027d9190810190613998565b61090d565b60405161028f9190613fb0565b60405180910390f35b3480156102a457600080fd5b506102ad610975565b6040516102ba9190614163565b60405180910390f35b3480156102cf57600080fd5b506102d861097a565b6040516102e59190614086565b60405180910390f35b3480156102fa57600080fd5b5061031560048036036103109190810190613a2b565b610a1c565b6040516103229190613ee3565b60405180910390f35b34801561033757600080fd5b50610352600480360361034d91908101906136e2565b610a6d565b005b34801561036057600080fd5b5061037b60048036036103769190810190613889565b610b29565b005b610385610c6e565b005b34801561039357600080fd5b506103ae60048036036103a991908101906137d2565b610f1f565b6040516103bb919061406b565b60405180910390f35b3480156103d057600080fd5b506103d9610f4f565b6040516103e69190614148565b60405180910390f35b3480156103fb57600080fd5b5061041660048036036104119190810190613a54565b610f5c565b005b34801561042457600080fd5b5061043f600480360361043a91908101906136b9565b610faa565b60405161044c9190613f8e565b60405180910390f35b34801561046157600080fd5b5061047c60048036036104779190810190613783565b61100b565b005b34801561048a57600080fd5b506104a560048036036104a091908101906138c5565b611030565b005b3480156104b357600080fd5b506104ce60048036036104c99190810190613889565b611073565b6040516104db9190614148565b60405180910390f35b3480156104f057600080fd5b5061050b60048036036105069190810190613919565b6110ea565b005b34801561051957600080fd5b50610534600480360361052f9190810190613783565b6110ef565b005b34801561054257600080fd5b5061055d60048036036105589190810190613a2b565b611110565b60405161056a9190614148565b60405180910390f35b34801561057f57600080fd5b5061059a60048036036105959190810190613a2b565b611148565b6040516105a79190613ee3565b60405180910390f35b3480156105bc57600080fd5b506105d760048036036105d291908101906136b9565b6111c6565b6040516105e49190614148565b60405180910390f35b3480156105f957600080fd5b50610602611251565b005b34801561061057600080fd5b50610619611323565b6040516106269190613ee3565b60405180910390f35b34801561063b57600080fd5b5061064461134c565b6040516106519190613fb0565b60405180910390f35b34801561066657600080fd5b50610681600480360361067c91908101906136b9565b6113a3565b604051610694979695949392919061417e565b60405180910390f35b3480156106a957600080fd5b506106b261140a565b6040516106bf9190614086565b60405180910390f35b3480156106d457600080fd5b506106dd6114ac565b6040516106ea9190614148565b60405180910390f35b3480156106ff57600080fd5b506107086114b1565b6040516107159190614148565b60405180910390f35b34801561072a57600080fd5b506107456004803603610740919081019061384d565b6114bd565b005b34801561075357600080fd5b5061076e60048036036107699190810190613a2b565b6115f5565b60405161077f959493929190614009565b60405180910390f35b34801561079457600080fd5b506107af60048036036107aa91908101906137d2565b6116da565b005b3480156107bd57600080fd5b506107d860048036036107d3919081019061370b565b611702565b005b3480156107e657600080fd5b5061080160048036036107fc9190810190613a2b565b611799565b60405161081093929190613fcb565b60405180910390f35b34801561082557600080fd5b50610840600480360361083b9190810190613a2b565b611ffd565b60405161084d9190614086565b60405180910390f35b34801561086257600080fd5b5061086b6120c6565b6040516108789190614163565b60405180910390f35b34801561088d57600080fd5b506108a860048036036108a39190810190613747565b6120cb565b6040516108b59190613fb0565b60405180910390f35b3480156108ca57600080fd5b506108e560048036036108e091908101906136b9565b61215f565b005b601360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600060016000837bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916815260200190815260200160002060009054906101000a900460ff169050919050565b603281565b6060600a8054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610a125780601f106109e757610100808354040283529160200191610a12565b820191906000526020600020905b8154815290600101906020018083116109f557829003601f168201915b5050505050905090565b6000610a278261217e565b1515610a3257600080fd5b6003600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b610a7561134c565b1515610a8057600080fd5b80601360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550601360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167fc107e672c8fedf7b9c82f11edfe1b1095102ff92cbd17ac360fc508c1ec3de1a60405160405180910390a250565b6000610b3482611148565b90508073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614151515610b7157600080fd5b8073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480610bb15750610bb081336120cb565b5b1515610bbc57600080fd5b826003600084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550818373ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b92560405160405180910390a4505050565b60fa60ff16610c7b610f4f565b101515610cbd576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610cb490614108565b60405180910390fd5b610cc5611323565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141515610e64576703d0ff0b013b80003410151515610d46576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610d3d906140c8565b60405180910390fd5b6000610d5d610d56600f346121f0565b606461222e565b9050600073ffffffffffffffffffffffffffffffffffffffff16601360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614151515610df3576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610dea906140e8565b60405180910390fd5b601360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166108fc8234039081150290604051600060405180830381858888f19350505050158015610e5d573d6000803e3d6000fd5b5050610eb4565b603260ff16610e71610f4f565b101515610eb3576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610eaa906140a8565b60405180910390fd5b5b6060610ec8610ec36012612258565b612266565b9050610edd33610ed86012612258565b6123bf565b610f12610eea6012612258565b610f0d6060604051908101604052806038815260200161447e60389139846123e0565b612427565b610f1c6012612467565b50565b600063150b7a027c0100000000000000000000000000000000000000000000000000000000029050949350505050565b6000600880549050905090565b610f6461134c565b1515610f6f57600080fd5b610f798282612427565b817fb3cbb6e549295716426a3c3b711cfeda7303d2c3cba225a8fb69cb06bdec178560405160405180910390a25050565b6060610fb58261247d565b805480602002602001604051908101604052809291908181526020018280548015610fff57602002820191906000526020600020905b815481526020019060010190808311610feb575b50505050509050919050565b61101533826124c5565b151561102057600080fd5b61102b83838361255a565b505050565b61106f828260006040519080825280601f01601f1916602001820160405280156110695781602001600182028038833980820191505090505b506110ea565b5050565b600061107e836111c6565b8210151561108b57600080fd5b600660008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020828154811015156110d757fe5b9060005260206000200154905092915050565b505050565b61110b83838360206040519081016040528060008152506116da565b505050565b600061111a610f4f565b8210151561112757600080fd5b60088281548110151561113657fe5b90600052602060002001549050919050565b6000806002600084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141515156111bd57600080fd5b80915050919050565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415151561120357600080fd5b61124a600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020612258565b9050919050565b61125961134c565b151561126457600080fd5b600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360008060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614905090565b6000806000806000806060601360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1694506703d0ff0b013b80009350600f925060fa9650603295506113f2610f4f565b91506113fd88610faa565b9050919395979092949650565b6060600b8054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156114a25780601f10611477576101008083540402835291602001916114a2565b820191906000526020600020905b81548152906001019060200180831161148557829003601f168201915b5050505050905090565b600f81565b6703d0ff0b013b800081565b3373ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141515156114f857600080fd5b80600560003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055508173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167f17307eab39ab6107e8899845ad3d59bd9653f200f220920489ca2b5937696c31836040516115e99190613fb0565b60405180910390a35050565b6000606061160161334c565b6060600061160e86611799565b8095508196508297505050503073ffffffffffffffffffffffffffffffffffffffff1663c87b56dd876040518263ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040161166f9190614148565b60006040518083038186803b15801561168757600080fd5b505afa15801561169b573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052506116c491908101906139ea565b91506116cf86611148565b905091939590929450565b6116e584848461100b565b6116f18484848461257e565b15156116fc57600080fd5b50505050565b61170a61134c565b151561171557600080fd5b8173ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f1935050505015801561175b573d6000803e3d6000fd5b507feaff4b37086828766ad3268786972c0cd24259d4c87a80f9d3963a3c3d999b0d828260405161178d929190613f65565b60405180910390a15050565b600060606117a561334c565b6117ad61134c565b15156117fe576117bc8461217e565b15156117fd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016117f490614128565b60405180910390fd5b5b836040516020018082815260200191505060405160208183030381529060405280519060200120925060006020905060038160ff1681151561183c57fe5b0460ff1660405190808252806020026020018201604052801561187957816020015b611866613382565b81526020019060019003908161185e5790505b509250600080905060008090505b84518160ff161015611d5c576000600f7f0100000000000000000000000000000000000000000000000000000000000000026004888560ff166020811015156118cc57fe5b1a7f0100000000000000000000000000000000000000000000000000000000000000027effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908060020a8204915050167f0100000000000000000000000000000000000000000000000000000000000000900490506000600f7f010000000000000000000000000000000000000000000000000000000000000002888560ff1660208110151561197857fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002167f0100000000000000000000000000000000000000000000000000000000000000900490506000600f7f01000000000000000000000000000000000000000000000000000000000000000260048a8760010197508760ff16602081101515611a0057fe5b1a7f0100000000000000000000000000000000000000000000000000000000000000027effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908060020a8204915050167f0100000000000000000000000000000000000000000000000000000000000000900490506000600f7f0100000000000000000000000000000000000000000000000000000000000000028a8760ff16602081101515611aac57fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002167f0100000000000000000000000000000000000000000000000000000000000000900490506000600f7f01000000000000000000000000000000000000000000000000000000000000000260048c8960010199508960ff16602081101515611b3457fe5b1a7f0100000000000000000000000000000000000000000000000000000000000000027effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908060020a8204915050167f0100000000000000000000000000000000000000000000000000000000000000900490506000600f7f0100000000000000000000000000000000000000000000000000000000000000028c8960ff16602081101515611be057fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002167f0100000000000000000000000000000000000000000000000000000000000000900490506000611c43611c3c8460ff1660646126cf565b600f612721565b9050605a8161ffff161115611c5757605a90505b6000611c71611c6a8760ff1660646126cf565b600f612721565b9050611c7b6133ee565b610120604051908101604052808b60ff1681526020018a60ff1681526020018960ff1681526020018860ff1681526020018760ff168152602001611cce611cc78c60ff166101686126cf565b600f612721565b61ffff168152602001605f8461ffff1611611ce95783611cec565b605f5b61ffff1681526020018461ffff16815260200160018660ff1610611d105785611d13565b60015b60ff1661ffff1681525090508a806001019b5050808e8b60ff16815181101515611d3957fe5b906020019060200201819052505050505050505050508080600101915050611887565b50608060405190810160405280600f7f0100000000000000000000000000000000000000000000000000000000000000026004888560ff16602081101515611da057fe5b1a7f0100000000000000000000000000000000000000000000000000000000000000027effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908060020a8204915050167f0100000000000000000000000000000000000000000000000000000000000000900460ff168152602001600f7f010000000000000000000000000000000000000000000000000000000000000002878460ff16602081101515611e5057fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002167f0100000000000000000000000000000000000000000000000000000000000000900460ff168152602001600f7f0100000000000000000000000000000000000000000000000000000000000000026004888560010195508560ff16602081101515611edc57fe5b1a7f0100000000000000000000000000000000000000000000000000000000000000027effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908060020a8204915050167f0100000000000000000000000000000000000000000000000000000000000000900460ff168152602001611feb611fe4600f7f010000000000000000000000000000000000000000000000000000000000000002898660ff16602081101515611f9257fe5b1a7f010000000000000000000000000000000000000000000000000000000000000002167f0100000000000000000000000000000000000000000000000000000000000000900460ff166101686126cf565b600f612721565b61ffff16815250925050509193909250565b60606120088261217e565b151561201357600080fd5b600c60008381526020019081526020016000208054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156120ba5780601f1061208f576101008083540402835291602001916120ba565b820191906000526020600020905b81548152906001019060200180831161209d57829003601f168201915b50505050509050919050565b60fa81565b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b61216761134c565b151561217257600080fd5b61217b81612757565b50565b6000806002600084815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415915050919050565b6000808314156122035760009050612228565b6000828402905082848281151561221657fe5b0414151561222357600080fd5b809150505b92915050565b6000808211151561223e57600080fd5b6000828481151561224b57fe5b0490508091505092915050565b600081600001549050919050565b606060008214156122ae576040805190810160405280600181526020017f300000000000000000000000000000000000000000000000000000000000000081525090506123ba565b600082905060005b6000821415156122dc578080600101915050600a828115156122d457fe5b0491506122b6565b6060816040519080825280601f01601f1916602001820160405280156123115781602001600182028038833980820191505090505b50905060006001830390505b6000861415156123b257600a8681151561233357fe5b066030017f01000000000000000000000000000000000000000000000000000000000000000282828060019003935081518110151561236e57fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350600a868115156123aa57fe5b04955061231d565b819450505050505b919050565b6123c98282612851565b6123d3828261299b565b6123dc81612a62565b5050565b606061241f8383602060405190810160405280600081525060206040519081016040528060008152506020604051908101604052806000815250612aae565b905092915050565b6124308261217e565b151561243b57600080fd5b80600c6000848152602001908152602001600020908051906020019061246292919061345a565b505050565b6001816000016000828254019250508190555050565b6000600660008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050919050565b6000806124d183611148565b90508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff16148061254057508373ffffffffffffffffffffffffffffffffffffffff1661252884610a1c565b73ffffffffffffffffffffffffffffffffffffffff16145b80612551575061255081856120cb565b5b91505092915050565b612565838383612ec9565b61256f8382613090565b612579828261299b565b505050565b600061259f8473ffffffffffffffffffffffffffffffffffffffff16613234565b15156125ae57600190506126c7565b60008473ffffffffffffffffffffffffffffffffffffffff1663150b7a02338887876040518563ffffffff167c010000000000000000000000000000000000000000000000000000000002815260040161260b9493929190613f19565b602060405180830381600087803b15801561262557600080fd5b505af1158015612639573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525061265d91908101906139c1565b905063150b7a027c0100000000000000000000000000000000000000000000000000000000027bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916817bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916149150505b949350505050565b6000808361ffff1614156126e6576000905061271b565b600082840290508261ffff168461ffff168261ffff1681151561270557fe5b0461ffff1614151561271657600080fd5b809150505b92915050565b6000808261ffff1611151561273557600080fd5b60008261ffff168461ffff1681151561274a57fe5b0490508091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415151561279357600080fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415151561288d57600080fd5b6128968161217e565b1515156128a257600080fd5b816002600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555061293b600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020612467565b808273ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a45050565b600660008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805490506007600083815260200190815260200160002081905550600660008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208190806001815401808255809150509060018203906000526020600020016000909192909190915055505050565b6008805490506009600083815260200190815260200160002081905550600881908060018154018082558091505090600182039060005260206000200160009091929091909150555050565b6060808690506060869050606086905060608690506060869050606081518351855187518951010101016040519080825280601f01601f191660200182016040528015612b0a5781602001600182028038833980820191505090505b509050606081905060008090506000809050600090505b8851811015612bd4578881815181101515612b3857fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f0100000000000000000000000000000000000000000000000000000000000000028383806001019450815181101515612b9757fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080600101915050612b21565b600090505b8751811015612c8c578781815181101515612bf057fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f0100000000000000000000000000000000000000000000000000000000000000028383806001019450815181101515612c4f57fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080600101915050612bd9565b600090505b8651811015612d44578681815181101515612ca857fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f0100000000000000000000000000000000000000000000000000000000000000028383806001019450815181101515612d0757fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080600101915050612c91565b600090505b8551811015612dfc578581815181101515612d6057fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f0100000000000000000000000000000000000000000000000000000000000000028383806001019450815181101515612dbf57fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080600101915050612d49565b600090505b8451811015612eb4578481815181101515612e1857fe5b9060200101517f010000000000000000000000000000000000000000000000000000000000000090047f0100000000000000000000000000000000000000000000000000000000000000028383806001019450815181101515612e7757fe5b9060200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508080600101915050612e01565b82995050505050505050505095945050505050565b8273ffffffffffffffffffffffffffffffffffffffff16612ee982611148565b73ffffffffffffffffffffffffffffffffffffffff16141515612f0b57600080fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614151515612f4757600080fd5b612f5081613247565b612f97600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020613307565b612fde600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020612467565b816002600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550808273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60405160405180910390a4505050565b60006130e86001600660008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054905061332a90919063ffffffff16565b905060006007600084815260200190815260200160002054905081811415156131db576000600660008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208381548110151561315957fe5b9060005260206000200154905080600660008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020838154811015156131b357fe5b9060005260206000200181905550816007600083815260200190815260200160002081905550505b600660008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080548091906001900361322d91906134da565b5050505050565b600080823b905060008111915050919050565b600073ffffffffffffffffffffffffffffffffffffffff166003600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415156133045760006003600083815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505b50565b61331f6001826000015461332a90919063ffffffff16565b816000018190555050565b600082821115151561333b57600080fd5b600082840390508091505092915050565b608060405190810160405280600060ff168152602001600060ff168152602001600060ff168152602001600061ffff1681525090565b61012060405190810160405280600060ff168152602001600060ff168152602001600060ff168152602001600060ff168152602001600060ff168152602001600061ffff168152602001600061ffff168152602001600061ffff168152602001600061ffff1681525090565b61012060405190810160405280600060ff168152602001600060ff168152602001600060ff168152602001600060ff168152602001600060ff168152602001600061ffff168152602001600061ffff168152602001600061ffff168152602001600061ffff1681525090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1061349b57805160ff19168380011785556134c9565b828001600101855582156134c9579182015b828111156134c85782518255916020019190600101906134ad565b5b5090506134d69190613506565b5090565b815481835581811115613501578183600052602060002091820191016135009190613506565b5b505050565b61352891905b8082111561352457600081600090555060010161350c565b5090565b90565b60006135378235614384565b905092915050565b600061354b8235614396565b905092915050565b600061355f82356143a8565b905092915050565b600061357382356143b4565b905092915050565b600061358782356143be565b905092915050565b600061359b82516143be565b905092915050565b600082601f83011215156135b657600080fd5b81356135c96135c482614221565b6141f4565b915080825260208301602083018583830111156135e557600080fd5b6135f083828461442a565b50505092915050565b600082601f830112151561360c57600080fd5b813561361f61361a8261424d565b6141f4565b9150808252602083016020830185838301111561363b57600080fd5b61364683828461442a565b50505092915050565b600082601f830112151561366257600080fd5b81516136756136708261424d565b6141f4565b9150808252602083016020830185838301111561369157600080fd5b61369c838284614439565b50505092915050565b60006136b182356143ea565b905092915050565b6000602082840312156136cb57600080fd5b60006136d98482850161352b565b91505092915050565b6000602082840312156136f457600080fd5b60006137028482850161353f565b91505092915050565b6000806040838503121561371e57600080fd5b600061372c8582860161353f565b925050602061373d858286016136a5565b9150509250929050565b6000806040838503121561375a57600080fd5b60006137688582860161352b565b92505060206137798582860161352b565b9150509250929050565b60008060006060848603121561379857600080fd5b60006137a68682870161352b565b93505060206137b78682870161352b565b92505060406137c8868287016136a5565b9150509250925092565b600080600080608085870312156137e857600080fd5b60006137f68782880161352b565b94505060206138078782880161352b565b9350506040613818878288016136a5565b925050606085013567ffffffffffffffff81111561383557600080fd5b613841878288016135a3565b91505092959194509250565b6000806040838503121561386057600080fd5b600061386e8582860161352b565b925050602061387f85828601613553565b9150509250929050565b6000806040838503121561389c57600080fd5b60006138aa8582860161352b565b92505060206138bb858286016136a5565b9150509250929050565b600080604083850312156138d857600080fd5b60006138e685828601613567565b925050602083013567ffffffffffffffff81111561390357600080fd5b61390f858286016135f9565b9150509250929050565b60008060006060848603121561392e57600080fd5b600061393c86828701613567565b935050602084013567ffffffffffffffff81111561395957600080fd5b613965868287016135f9565b925050604084013567ffffffffffffffff81111561398257600080fd5b61398e868287016135a3565b9150509250925092565b6000602082840312156139aa57600080fd5b60006139b88482850161357b565b91505092915050565b6000602082840312156139d357600080fd5b60006139e18482850161358f565b91505092915050565b6000602082840312156139fc57600080fd5b600082015167ffffffffffffffff811115613a1657600080fd5b613a228482850161364f565b91505092915050565b600060208284031215613a3d57600080fd5b6000613a4b848285016136a5565b91505092915050565b60008060408385031215613a6757600080fd5b6000613a75858286016136a5565b925050602083013567ffffffffffffffff811115613a9257600080fd5b613a9e858286016135f9565b9150509250929050565b613ab1816143f4565b82525050565b613ac0816142eb565b82525050565b613acf816142d9565b82525050565b6000613ae082614293565b808452602084019350613af283614279565b60005b82811015613b2557613b08868351613dff565b613b11826142bf565b915061012086019550600181019050613af5565b50849250505092915050565b6000613b3c8261429e565b808452602084019350613b4e83614286565b60005b82811015613b8057613b64868351613ec5565b613b6d826142cc565b9150602086019550600181019050613b51565b50849250505092915050565b613b95816142fd565b82525050565b613ba481614309565b82525050565b613bb381614313565b82525050565b6000613bc4826142a9565b808452613bd8816020860160208601614439565b613be18161446c565b602085010191505092915050565b6000613bfa826142b4565b808452613c0e816020860160208601614439565b613c178161446c565b602085010191505092915050565b6000602882527f4d6178206e756d6265722063726561746f7220746f6b656e7320616c7265616460208301527f79206973737565640000000000000000000000000000000000000000000000006040830152606082019050919050565b6000602682527f496e73756666696369656e74204554482073656e742077697468207472616e7360208301527f616374696f6e00000000000000000000000000000000000000000000000000006040830152606082019050919050565b6000601982527f43617573652042656e6566696369617279206e6f7420736574000000000000006020830152604082019050919050565b6000601182527f4d617820746f6b656e73206973737565640000000000000000000000000000006020830152604082019050919050565b6000602282527f52657175657374656420746f6b656e20646f6573206e6f74206578697374207960208301527f65740000000000000000000000000000000000000000000000000000000000006040830152606082019050919050565b608082016000820151613dc06000850182613ed4565b506020820151613dd36020850182613ed4565b506040820151613de66040850182613ed4565b506060820151613df96060850182613eb6565b50505050565b61012082016000820151613e166000850182613ed4565b506020820151613e296020850182613ed4565b506040820151613e3c6040850182613ed4565b506060820151613e4f6060850182613ed4565b506080820151613e626080850182613ed4565b5060a0820151613e7560a0850182613eb6565b5060c0820151613e8860c0850182613eb6565b5060e0820151613e9b60e0850182613eb6565b50610100820151613eb0610100850182613eb6565b50505050565b613ebf8161433f565b82525050565b613ece8161436d565b82525050565b613edd81614377565b82525050565b6000602082019050613ef86000830184613ac6565b92915050565b6000602082019050613f136000830184613ab7565b92915050565b6000608082019050613f2e6000830187613aa8565b613f3b6020830186613ac6565b613f486040830185613ec5565b8181036060830152613f5a8184613bb9565b905095945050505050565b6000604082019050613f7a6000830185613aa8565b613f876020830184613ec5565b9392505050565b60006020820190508181036000830152613fa88184613b31565b905092915050565b6000602082019050613fc56000830184613b8c565b92915050565b600060c082019050613fe06000830186613b9b565b8181036020830152613ff28185613ad5565b90506140016040830184613daa565b949350505050565b60006101008201905061401f6000830188613b9b565b81810360208301526140318187613ad5565b90506140406040830186613daa565b81810360c08301526140528185613bef565b905061406160e0830184613ac6565b9695505050505050565b60006020820190506140806000830184613baa565b92915050565b600060208201905081810360008301526140a08184613bef565b905092915050565b600060208201905081810360008301526140c181613c25565b9050919050565b600060208201905081810360008301526140e181613c82565b9050919050565b6000602082019050818103600083015261410181613cdf565b9050919050565b6000602082019050818103600083015261412181613d16565b9050919050565b6000602082019050818103600083015261414181613d4d565b9050919050565b600060208201905061415d6000830184613ec5565b92915050565b60006020820190506141786000830184613ed4565b92915050565b600060e082019050614193600083018a613ed4565b6141a06020830189613ed4565b6141ad6040830188613ac6565b6141ba6060830187613ec5565b6141c76080830186613ec5565b6141d460a0830185613ec5565b81810360c08301526141e68184613b31565b905098975050505050505050565b6000604051905081810181811067ffffffffffffffff8211171561421757600080fd5b8060405250919050565b600067ffffffffffffffff82111561423857600080fd5b601f19601f8301169050602081019050919050565b600067ffffffffffffffff82111561426457600080fd5b601f19601f8301169050602081019050919050565b6000602082019050919050565b6000602082019050919050565b600081519050919050565b600081519050919050565b600081519050919050565b600081519050919050565b6000602082019050919050565b6000602082019050919050565b60006142e48261434d565b9050919050565b60006142f68261434d565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b600061ffff82169050919050565b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000819050919050565b600060ff82169050919050565b600061438f8261434d565b9050919050565b60006143a18261434d565b9050919050565b60008115159050919050565b6000819050919050565b60007fffffffff0000000000000000000000000000000000000000000000000000000082169050919050565b6000819050919050565b60006143ff82614406565b9050919050565b600061441182614418565b9050919050565b60006144238261434d565b9050919050565b82818337600083830152505050565b60005b8381101561445757808201518184015260208101905061443c565b83811115614466576000848401525b50505050565b6000601f19601f830116905091905056fe68747470733a2f2f6170692e67656e657238746976652e696f2f6b636f6d706f736974696f6e732f746f6b656e732f6d657461646174612fa265627a7a7230582007c1d574a49a12a38c33f71ecb0b2480a604b289ae86922c36d36dbfc30a69ba6c6578706572696d656e74616cf50037

Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)

000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a0000000000000000000000000c7464dbca260a8faf033460622b23467df5aea42000000000000000000000000000000000000000000000000000000000000001947656e65723874697665204b2d436f6d706f736974696f6e7300000000000000000000000000000000000000000000000000000000000000000000000000000447ea9ea200000000000000000000000000000000000000000000000000000000

-----Decoded View---------------
Arg [0] : _name (string): Gener8tive K-Compositions
Arg [1] : _symbol (string): GꞢ
Arg [2] : _causeBeneficiary (address): 0xc7464dbcA260A8faF033460622B23467Df5AEA42

-----Encoded View---------------
7 Constructor Arguments found :
Arg [0] : 0000000000000000000000000000000000000000000000000000000000000060
Arg [1] : 00000000000000000000000000000000000000000000000000000000000000a0
Arg [2] : 000000000000000000000000c7464dbca260a8faf033460622b23467df5aea42
Arg [3] : 0000000000000000000000000000000000000000000000000000000000000019
Arg [4] : 47656e65723874697665204b2d436f6d706f736974696f6e7300000000000000
Arg [5] : 0000000000000000000000000000000000000000000000000000000000000004
Arg [6] : 47ea9ea200000000000000000000000000000000000000000000000000000000


Swarm Source

bzzr://07c1d574a49a12a38c33f71ecb0b2480a604b289ae86922c36d36dbfc30a69ba
Loading...
Loading
Loading...
Loading
[ Download: CSV Export  ]
[ Download: CSV Export  ]

A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.