Skip to content

Instantly share code, notes, and snippets.

Created Feb 5, 2016
What would you like to do?
Created using soleditor: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at
contract random{
/* Define variable owner of the type address*/
address owner;
/* this function is executed at initialization and sets the owner of the contract */
function Random() { owner = msg.sender; }
/* Function to recover the funds on the contract */
function kill() { if (msg.sender == owner) suicide(owner); }
//generate random number
function rand( uint256 seedB ) returns (uint256){
//define seedA variable
uint256 seedA = 1;
uint amount = 1 finney;
if (seedA == seedB) {
return seedA + seedB;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment