Contract Overview
Balance: 0 Ether
Ether Value: $0
Transactions: 61 txns
Misc:
Address Watch: Add To Watch List
Contract Creator: 0x008adda353dbbdc5def9897e0406511af690385bat txn 0xb89e50b50e7ce5ac6a93a02aa840e720622f4ac2c4e9f426efd1d1c451887f64
 Latest 25 transactions from a total of 61 transactions

TxHash Age From To Value [TxFee]
0x78fa1340809d91c05c7f4dcb96e06fd921c95b4204990cd6654d8e9378f9778c2 hrs 39 mins ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.00171756
0xeaf43fa15e7dc9eca4ce171510777e7d8f109b8dad7c3ad1fe3be54b37946ca02 hrs 41 mins ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.00171756
0xde28ef749e87f2b96d6c38e5f04d7e0b3cf2822a9889c9ff6ca509dd28df1a6b2 hrs 43 mins ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.00171756
0x47308a12510d0e63a5b05ff2a951ec7ad99aad5c990e0cb6c0b9d2b6941e572015 days 1 hr ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.001202292
0x3b89aca86aecab8b64bc2a544d9b20043834bd47030dfb01b1ced3dda25112a215 days 1 hr ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.00118017674
0xeee38924b50d8c1631264ac104946996ffcee1e39da1bd319614e2e2eb2a33e315 days 1 hr ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.00119026908
0x64f070411afda5bd8cf2b1a3cc475999458e2a691ea426f34dcb3275184b3da731 days 5 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.000944658
0x9a931c89135bee95840ae981dd0600ba51cbe81a3df5478aa19e648f986c2ded31 days 5 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.0008931312
0xc25beb3943bf3ebe6955820a0ce276977b102e22deb7b43a512890afd6c4511131 days 5 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.0008931312
0x7eb4f1f15d072c2f2bc91c51c077576eee3f412dadf0f7788acabbfdd10874ba31 days 5 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.0009274824
0x67dd95f57047a0b279e84d9d18546fc271ae259a7c4fb72d6f7e8a7f942c326031 days 5 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.0009103068
0xb169168fcbf22c6e316f4525c4b73bfa9999f7f165c775bc227f0b186a9de23831 days 5 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.0008927984
0x71bc37d6332587e06d44923137b35e2723b35cac57739cbb58425f4efdb21ed831 days 5 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.0008927984
0xedd1d8be477abe6c5fee7c7e81ce2f2ec17fe4f2f946803e8b4c493a636904fc31 days 5 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.0009274824
0x45c60d6f133ba9b7c3d20a71328851d52ea92fa778f64a96284e0361cc44b7ef31 days 5 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.000944658
0x59acf4166b2c05890ad55d8fb996d163f5c40cd582263420f126298840278b0045 days 19 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.00171756
0xe13ea21c98bdb160f952f754eb22e9c277df56ac4b3e4a3deaa037d116120ae145 days 19 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.001545804
0xaea4aa176864debe766e38782b4f39e3ed33fd0618b61b3addca2fa012fa05b145 days 19 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.001545804
0x1aef4d3f0f349619732bbc531fd31ca3b38c60d62f010fc3aa10171de149328e45 days 19 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.001545804
0x49e9fa29b26301384553df9b9d3705714e37cf6d84a398a6c6c459a14ecfd63445 days 19 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.001545804
0x682887af3eb3d9f7effcc0d91d6e4acda86d2a29d9fc46d911a084248f1ee02345 days 19 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.002061072
0x059e8aacec45cb3b1a39af977bad7fcda0bdfe918df1b265a34f979858d252e745 days 19 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.00171692
0xddcd634a64b4f04fbde617fa79d252e8290258b9e384bc2595c25f9b8bbb138045 days 19 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.001545804
0x8240402b83e04c3b23af86535a59234c6151a313567a9290bb2a0148c62010cf45 days 19 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.001545228
0xba9dd4ebdba213b32648636cd97e0254873a7d60705fd0b92a9d288f396e4e2545 days 19 hrs ago0x008adda353dbbdc5def9897e0406511af690385b  IN   0xf912efb4e59cd2910d90a78b1c1491a870c54b120 Ether0.00135
[ Download CSV Export  ] 
 Internal Transactions as a result of Contract Execution
View All
ParentTxHash Block Age From To Value
Contract Source Code Verified (Exact Match)
Contract Name: ZmineRandom
Compiler Text: v0.4.25+commit.59dbf8f1
Optimization Enabled: Yes
Runs (Optimiser):  200



  Contract Source Code   Find Similiar Contracts

pragma solidity 0.4.25;

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

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

    /**
     * @dev The Ownable constructor sets the original `owner` of the contract to the sender
     * account.
     */
    constructor() public {
        owner = msg.sender;
    }
    /**
     * @dev Throws if called by any account other than the owner.
     */
    modifier onlyOwner() {
        require(msg.sender == owner);
        _;
    }

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

/**
 * @title Authorizable
 * @dev The Authorizable contract has authorized addresses, and provides basic authorization control
 * functions, this simplifies the implementation of "multiple user permissions".
 */
contract Authorizable is Ownable {
    
    mapping(address => bool) public authorized;
    event AuthorizationSet(address indexed addressAuthorized, bool indexed authorization);

    /**
     * @dev The Authorizable constructor sets the first `authorized` of the contract to the sender
     * account.
     */
    constructor() public {
        authorize(msg.sender);
    }

    /**
     * @dev Throws if called by any account other than the authorized.
     */
    modifier onlyAuthorized() {
        require(authorized[msg.sender]);
        _;
    }

    /**
     * @dev Allows 
     * @param _address The address to change authorization.
     */
    function authorize(address _address) public onlyOwner {
        require(!authorized[_address]);
        emit AuthorizationSet(_address, true);
        authorized[_address] = true;
    }
    /**
     * @dev Disallows
     * @param _address The address to change authorization.
     */
    function deauthorize(address _address) public onlyOwner {
        require(authorized[_address]);
        emit AuthorizationSet(_address, false);
        authorized[_address] = false;
    }
}

contract ZmineRandom is Authorizable {
    
    uint256 public counter = 0;
    mapping(uint256 => uint256) public randomResultMap;
    mapping(uint256 => uint256[]) public randomInputMap;
    
 
    function random(uint256 min, uint256 max, uint256 lotto) public onlyAuthorized  {
        
		require(min > 0);
        require(max > min);
         
        counter++;
        uint256 result = ((uint256(keccak256(abi.encodePacked(lotto))) 
                        + uint256(keccak256(abi.encodePacked(counter))) 
                        + uint256(keccak256(abi.encodePacked(block.difficulty)))
                        + uint256(keccak256(abi.encodePacked(block.number - 1)))
                    ) % (max-min+1)) - min;
        
        uint256[] memory array = new uint256[](5);
        array[0] = min;
        array[1] = max;
        array[2] = lotto;
        array[3] = block.difficulty;
        array[4] = block.number;
        randomInputMap[counter] = array;
         
        randomResultMap[counter] = result;
    }

    function checkHash(uint256 n) public pure returns (uint256){
        return uint256(keccak256(abi.encodePacked(n)));
    }
}

    Contract ABI  
[{"constant":false,"inputs":[{"name":"_address","type":"address"}],"name":"deauthorize","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"n","type":"uint256"}],"name":"checkHash","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"pure","type":"function"},{"constant":true,"inputs":[],"name":"counter","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"min","type":"uint256"},{"name":"max","type":"uint256"},{"name":"lotto","type":"uint256"}],"name":"random","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_address","type":"address"}],"name":"authorize","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"","type":"uint256"}],"name":"randomResultMap","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"authorized","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"},{"constant":true,"inputs":[{"name":"","type":"uint256"},{"name":"","type":"uint256"}],"name":"randomInputMap","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"anonymous":false,"inputs":[{"indexed":true,"name":"addressAuthorized","type":"address"},{"indexed":true,"name":"authorization","type":"bool"}],"name":"AuthorizationSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"previousOwner","type":"address"},{"indexed":true,"name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"}]

  Contract Creation Code Switch To Opcodes View
6080604052600060028190558054600160a060020a0319163390811790915561003090640100000000610035810204565b6100d0565b600054600160a060020a0316331461004c57600080fd5b600160a060020a03811660009081526001602052604090205460ff161561007257600080fd5b604051600190600160a060020a038316907f5056a36abc1db1625034fdf114a164a0345b3ccf992fc1d51055e017375f473290600090a3600160a060020a03166000908152600160208190526040909120805460ff19169091179055565b61085f806100df6000396000f3006080604052600436106100a35763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166327c97fa581146100a85780633d76b7a3146100cb57806361bc221a146100f55780637299054c1461010a5780638da5cb5b14610128578063b6a5d7de14610159578063b9035c171461017a578063b918161114610192578063f2fde38b146101c7578063f65a74dc146101e8575b600080fd5b3480156100b457600080fd5b506100c9600160a060020a0360043516610203565b005b3480156100d757600080fd5b506100e3600435610298565b60408051918252519081900360200190f35b34801561010157600080fd5b506100e361031b565b34801561011657600080fd5b506100c9600435602435604435610321565b34801561013457600080fd5b5061013d610636565b60408051600160a060020a039092168252519081900360200190f35b34801561016557600080fd5b506100c9600160a060020a0360043516610645565b34801561018657600080fd5b506100e36004356106e0565b34801561019e57600080fd5b506101b3600160a060020a03600435166106f2565b604080519115158252519081900360200190f35b3480156101d357600080fd5b506100c9600160a060020a0360043516610707565b3480156101f457600080fd5b506100e360043560243561079b565b600054600160a060020a0316331461021a57600080fd5b600160a060020a03811660009081526001602052604090205460ff16151561024157600080fd5b604051600090600160a060020a038316907f5056a36abc1db1625034fdf114a164a0345b3ccf992fc1d51055e017375f4732908390a3600160a060020a03166000908152600160205260409020805460ff19169055565b600081604051602001808281526020019150506040516020818303038152906040526040518082805190602001908083835b602083106102e95780518252601f1990920191602091820191016102ca565b5181516020939093036101000a6000190180199091169216919091179052604051920182900390912095945050505050565b60025481565b3360009081526001602052604081205460609060ff16151561034257600080fd5b6000851161034f57600080fd5b84841161035b57600080fd5b6002805460019081019091556040805160001943016020808301919091528251808303820181529183019283905281518994858a030193918291908401908083835b602083106103bc5780518252601f19909201916020918201910161039d565b51815160209384036101000a60001901801990921691161790526040805192909401829003822044838301528451808403830181529285019485905282519096509194508392508401908083835b602083106104295780518252601f19909201916020918201910161040a565b51815160209384036101000a600019018019909216911617905260408051929094018290038220600254838301528451808403830181529285019485905282519096509194508392508401908083835b602083106104985780518252601f199092019160209182019101610479565b51815160209384036101000a6000190180199092169116179052604080519290940182900382208282018e90528451808403830181529285019485905282519096509194508392508401908083835b602083106105065780518252601f1990920191602091820191016104e7565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405180910390206001900401010181151561054357fe5b060391506005604051908082528060200260200182016040528015610572578160200160208202803883390190505b5090508481600081518110151561058557fe5b6020908102909101015280518490829060019081106105a057fe5b6020908102909101015280518390829060029081106105bb57fe5b6020908102909101015280514490829060039081106105d657fe5b6020908102909101015280514390829060049081106105f157fe5b602090810290910181019190915260025460009081526004825260409020825161061d928401906107cb565b5050600254600090815260036020526040902055505050565b600054600160a060020a031681565b600054600160a060020a0316331461065c57600080fd5b600160a060020a03811660009081526001602052604090205460ff161561068257600080fd5b604051600190600160a060020a038316907f5056a36abc1db1625034fdf114a164a0345b3ccf992fc1d51055e017375f473290600090a3600160a060020a03166000908152600160208190526040909120805460ff19169091179055565b60036020526000908152604090205481565b60016020526000908152604090205460ff1681565b600054600160a060020a0316331461071e57600080fd5b600160a060020a038116151561073357600080fd5b60008054604051600160a060020a03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a36000805473ffffffffffffffffffffffffffffffffffffffff1916600160a060020a0392909216919091179055565b6004602052816000526040600020818154811015156107b657fe5b90600052602060002001600091509150505481565b828054828255906000526020600020908101928215610806579160200282015b828111156108065782518255916020019190600101906107eb565b50610812929150610816565b5090565b61083091905b80821115610812576000815560010161081c565b905600a165627a7a72305820472d9bfef76d6056bd18b026db487e6be397fd41a31211630cf3f8da72e80fe20029

   Swarm Source:
bzzr://472d9bfef76d6056bd18b026db487e6be397fd41a31211630cf3f8da72e80fe2

 

View All
Block Age transaction Difficulty GasUsed Reward
View All
Block Age UncleNumber Difficulty GasUsed Reward
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.