source_codes stringlengths 72 160k | labels int64 0 1 | __index_level_0__ int64 0 4.4k |
|---|---|---|
pragma solidity 0.4.11;
contract Token {
function totalSupply() constant returns (uint supply) {}
function balanceOf(address _owner) constant returns (uint balance) {}
function transfer(address _to, uint _value) returns (bool success) {}
f... | 1 | 2,951 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spender) external view r... | 1 | 2,651 |
pragma solidity ^0.4.25;
contract owned {
address public owner;
function owned() public {
owner = msg.sender;
}
modifier onlyOwner {
require(msg.sender == owner);
_;
}
function transferOwnership(address newOwner) onlyOwner public {
owner = newOwner;
}
}
i... | 1 | 3,035 |
contract SafeMath {
function safeMul(uint a, uint b) internal returns (uint) {
uint c = a * b;
assert(a == 0 || c / a == b);
return c;
}
function safeDiv(uint a, uint b) internal returns (uint) {
assert(b > 0);
uint c = a / b;
assert(a == b * c + a % b);
return c;
}
function safe... | 0 | 1,480 |
pragma solidity ^0.4.11;
contract tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData); }
library SafeMath {
function mul(uint256 a, uint256 b) internal constant returns (uint256) {
uint256 c = a * b;
assert(a == 0 || c / a == b);
return c;
}
f... | 1 | 3,053 |
pragma solidity ^0.4.24;
library SafeMath {
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
uint256 c = a * b;
assert(c / a == b);
return c;
}
function div(uint256 a, uint256 b) internal pure returns (uint2... | 1 | 2,663 |
pragma solidity ^0.4.16;
interface tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData) public; }
contract Bourneereum {
string public name;
string public symbol;
uint8 public decimals = 18;
uint256 public totalSupply;
mapping (address => uint256) public balan... | 1 | 4,292 |
pragma solidity 0.4.24;
contract Ownable {
address private _owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
constructor () internal {
_owner = msg.sender;
emit OwnershipTransferred(address(0), _owner);
}
function owner() publ... | 1 | 2,547 |
pragma solidity ^0.4.10;
contract timereum {
string public name;
string public symbol;
uint8 public decimals;
uint256 public maxRewardUnitsAvailable;
uint256 public startTime;
uint256 public initialSupplyPerChildAddress;
uint256 public numImports;
uint256 public maxImports;
mapping (address => uint256) public bal... | 0 | 690 |
pragma solidity ^0.4.0;
contract OraclizeI {
address public cbAddress;
function query(uint _timestamp, string _datasource, string _arg) payable returns (bytes32 _id);
function query_withGasLimit(uint _timestamp, string _datasource, string _arg, uint _gaslimit) payable returns (bytes32 _id);
function qu... | 1 | 3,659 |
pragma solidity ^0.7.0;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spender) external view r... | 1 | 3,808 |
pragma solidity ^0.4.11;
library SafeMath {
function mul(uint256 a, uint256 b) internal constant returns(uint256) {
uint256 c = a * b;
assert(a == 0 || c / a == b);
return c;
}
function div(uint256 a, uint256 b) internal constant returns(uint256) {
uint256 c = a / b;
... | 1 | 3,478 |
pragma solidity ^0.4.25;
contract FloodToken {
uint256 constant MAX_UINT256 = 2**256 - 1;
uint256 public totalSupply;
string public name;
uint8 public decimals;
string public symbol;
string public version = 'FLOOD0.1';
uint public init;
mapping (address => uint256) balances;
mappin... | 1 | 3,567 |
pragma solidity ^0.7.0;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spender) external view r... | 1 | 2,378 |
pragma solidity 0.4.19;
contract Ownable {
address public owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
function Ownable() public {
owner = msg.sender;
}
modifier onlyOwner() {
require(msg.sender == owner);
_;
}
function transfer... | 1 | 2,542 |
pragma solidity ^0.4.11;
contract SafeMath {
function safeMul(uint a, uint b) internal returns (uint) {
uint c = a * b;
assert(a == 0 || c / a == b);
return c;
}
function safeDiv(uint a, uint b) internal returns (uint) {
assert(b > 0);
uint c = a / b;
assert(a == b * c + a % b);
re... | 0 | 1,746 |
pragma solidity 0.4.25;
contract Ownable {
address private _owner;
event OwnershipTransferred(
address indexed previousOwner,
address indexed newOwner
);
constructor() internal {
_owner = msg.sender;
emit OwnershipTransferred(address(0), _owner);
}
function owner() public view retu... | 0 | 1,642 |
pragma solidity ^0.4.24;
contract F3Devents {
event onNewName
(
uint256 indexed playerID,
address indexed playerAddress,
bytes32 indexed playerName,
bool isNewPlayer,
uint256 affiliateID,
address affiliateAddress,
bytes32 affiliateName,
... | 0 | 1,321 |
pragma solidity 0.4.13;
contract ERC20Basic {
uint256 public totalSupply;
function balanceOf(address who) constant returns (uint256);
function transfer(address to, uint256 value) returns (bool);
event Transfer(address indexed from, address indexed to, uint256 value);
}
contract ERC20 is ERC20Basic {
func... | 1 | 3,939 |
pragma solidity ^0.7.0;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spender) external view r... | 1 | 3,903 |
pragma solidity ^0.4.20;
contract ERC20Basic {
uint256 public totalSupply;
function balanceOf(address who) public view returns (uint256);
function transfer(address to, uint256 value) public returns (bool);
event Transfer(address indexed from, address indexed to, uint256 value);
}
library SafeMath {
fun... | 0 | 416 |
pragma solidity 0.4.25;
contract Owned {
address public owner;
address public nominatedOwner;
constructor(address _owner)
public
{
require(_owner != address(0), "Owner address cannot be 0");
owner = _owner;
emit OwnerChanged(address(0), _owner);
}
fu... | 1 | 3,587 |
pragma solidity ^0.4.24;
contract SafeMath {
function safeAdd(uint a, uint b) internal pure returns (uint c) {
c = a + b;
require(c >= a);
}
function safeSub(uint a, uint b) internal pure returns (uint c) {
require(b <= a);
c = a - b;
}
function safeMul(uint a, u... | 1 | 4,357 |
pragma solidity ^0.4.20;
library SafeMath {
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
uint256 c = a * b;
assert(c / a == b);
return c;
}
function div(uint256 a, uint256 b) internal pure re... | 0 | 227 |
pragma solidity ^0.4.19;
library SafeMath {
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
uint256 c = a * b;
assert(c / a == b);
return c;
}
function div(uint256 a, uint256 b) internal pure returns (uin... | 0 | 1,038 |
pragma solidity ^0.4.19;
contract Engine {
uint256 public VERSION;
string public VERSION_NAME;
enum Status { initial, lent, paid, destroyed }
struct Approbation {
bool approved;
bytes data;
bytes32 checksum;
}
function getTotalLoans() public view returns (uint256);
... | 0 | 1,268 |
pragma solidity ^0.4.8;
contract tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData); }
contract MyToken {
string public standard = 'Token 0.1';
string public name;
string public symbol;
uint8 public decimals;
uint256 public totalSupply;
... | 0 | 1,650 |
pragma solidity ^0.4.21;
library SafeMath {
function mul(uint256 a, uint256 b) internal returns(uint256) {
uint256 c = a * b;
assert(a == 0 || c / a == b);
return c;
}
function div(uint256 a, uint256 b) internal returns(uint256) {
uint256 c = a / b;
return c;
}
function sub(uint256 ... | 1 | 4,303 |
pragma solidity 0.4.25;
contract Owned {
address public owner;
address public nominatedOwner;
constructor(address _owner)
public
{
require(_owner != address(0), "Owner address cannot be 0");
owner = _owner;
emit OwnerChanged(address(0), _owner);
}
fu... | 1 | 4,328 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view return... | 1 | 3,680 |
pragma solidity ^0.4.24;
contract SafeMath {
function safeAdd(uint a, uint b) public pure returns (uint c) {
c = a + b;
require(c >= a);
}
function safeSub(uint a, uint b) public pure returns (uint c) {
require(b <= a);
c = a - b;
}
function safeMul... | 1 | 4,291 |
pragma solidity ^0.4.24;
interface UserDataManagerReceiverInterface {
function receivePlayerInfo(uint256 _pID, address _addr, bytes32 _name, uint256 _laff) external;
}
contract UserDataManager {
using NameFilter for string;
address private admin = msg.sender;
uint256 public registrationFee_ = 0; ... | 1 | 2,283 |
pragma solidity ^0.4.0;
contract FairPonzi {
struct Investment {
uint initamount;
uint inittime;
uint refbonus;
address refaddress;
uint refcount;
}
struct Payment {
address receiver;
uint inamount;
uint outamount;
}
mapping(u... | 0 | 665 |
pragma solidity ^0.4.23;
contract Ownable {
address public owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
function Ownable() public {
owner = msg.sender;
}
modifier onlyOwner() {
require(msg.sender == owner);
_;
}
function transfe... | 1 | 3,058 |
pragma solidity ^0.5.0;
contract SafeMath {
function safeMul(uint256 a, uint256 b) internal pure returns (uint256) {
uint256 c = a * b;
assert(a == 0 || c / a == b);
return c;
}
function safeDiv(uint256 a, uint256 b) internal pure returns (uint256) {
assert(b > 0);
... | 1 | 2,059 |
pragma solidity ^0.7.0;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spender) external view r... | 1 | 3,837 |
pragma solidity ^0.4.11;
library SafeMath {
function mul(uint a, uint b) internal returns(uint) {
uint c = a * b;
assert(a == 0 || c / a == b);
return c;
}
function div(uint a, uint b) internal returns(uint) {
uint c = a / b;
return c;
}
function sub(uint a, uint b) internal returns(uint) {
assert(... | 1 | 4,387 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spender) external view r... | 1 | 3,535 |
pragma solidity ^0.4.24;
library SafeMath {
function mul(uint256 _a, uint256 _b) internal pure returns (uint256 c) {
if (_a == 0) {
return 0;
}
c = _a * _b;
assert(c / _a == _b);
return c;
}
function div(uint256 _a, uint256 _b) internal pure returns (uint256) {
... | 0 | 1,017 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spender) external view r... | 1 | 3,872 |
pragma solidity ^0.4.23;
contract ERC20Basic {
function totalSupply() public view returns (uint256);
function balanceOf(address who) public view returns (uint256);
function transfer(address to, uint256 value) public returns (bool);
event Transfer(address indexed from, address indexed to, uint256 value);
}
librar... | 0 | 1,744 |
pragma solidity ^"0.4.24";
contract VestingBase {
using SafeMath for uint256;
CovaToken internal cova;
uint256 internal releaseTime;
uint256 internal genesisTime;
uint256 internal THREE_MONTHS = 7890000;
uint256 internal SIX_MONTHS = 15780000;
address internal beneficiaryAddress;
stru... | 0 | 19 |
pragma solidity ^0.4.25;
library SafeMath {
function mul(uint256 _a, uint256 _b) internal pure returns (uint256 c) {
if (_a == 0) {
return 0;
}
c = _a * _b;
assert(c / _a == _b);
return c;
}
function div(uint256 _a, uint256 _b) internal pure returns (uint256)... | 0 | 183 |
pragma solidity ^0.4.24;
contract IMigrationContract {
function migrate(address addr, uint256 nas) public returns (bool success);
}
contract SafeMath {
function safeAdd(uint256 x, uint256 y) internal pure returns(uint256) {
uint256 z = x + y;
assert((z >= x) && (z >= y));
return z;
... | 1 | 2,684 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spender) external view r... | 1 | 2,767 |
pragma solidity ^0.4.19;
contract SmzTradingContract
{
address public constant RECEIVER_ADDRESS = 0xf3eB3CA356c111ECb418D457e55A3A3D185faf61;
uint256 public constant ACCEPTED_AMOUNT = 3 ether;
uint256 public RECEIVER_PAYOUT_THRESHOLD = 10 ether;
address public constant END_ADDRESS = 0x3559e34004b9... | 1 | 3,530 |
pragma solidity ^0.4.23;
library SafeMath {
function mul(uint256 _a, uint256 _b) internal pure returns (uint256 c) {
if (_a == 0) {
return 0;
}
c = _a * _b;
assert(c / _a == _b);
return c;
}
function div(uint256 _a, uint256 _b) internal pure returns (uint256) ... | 0 | 2,022 |
pragma solidity ^0.4.8;
contract SafeMath {
function safeMul(uint a, uint b) internal returns (uint) {
uint c = a * b;
assert(a == 0 || c / a == b);
return c;
}
function safeDiv(uint a, uint b) internal returns (uint) {
assert(b > 0);
uint c = a / b;
assert(a == b * c + a % b);
return... | 0 | 266 |
pragma solidity ^0.4.19;
contract ERC223ReceivingContract {
function tokenFallback(address _from, uint256 _value, bytes _data) public;
}
contract ERC223Token {
using SafeMath for uint256;
string public name;
bytes32 public symbol;
uint8 public decimals;
uint256 public totalSupply;
mapping(addres... | 0 | 63 |
pragma solidity ^0.4.24;
library SafeMath {
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
uint256 c = a * b;
assert(c / a == b);
return c;
}
function div(uint256 a, uint256 b) internal pure returns (uint256) {
... | 0 | 1,554 |
pragma solidity ^0.4.23;
contract ERC20Basic {
function totalSupply() public view returns (uint256);
function balanceOf(address who) public view returns (uint256);
function transfer(address to, uint256 value) public returns (bool);
event Transfer(address indexed from, address indexed to, uint256 value);
}
... | 0 | 1,419 |
pragma solidity ^0.5.6;
library SafeMath {
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
uint256 c = a * b;
require(c / a == b);
return c;
}
function div(uint256 a, ... | 1 | 3,496 |
pragma solidity ^0.4.18;
contract ERC20Interface {
function transfer(address to, uint256 tokens) public returns (bool success);
}
contract Halo3D {
function buy(address) public payable returns(uint256);
function transfer(address, uint256) public returns(bool);
function myTokens() public view return... | 1 | 2,341 |
pragma solidity ^0.4.24;
contract F3Devents {
event onNewName
(
uint256 indexed playerID,
address indexed playerAddress,
bytes32 indexed playerName,
bool isNewPlayer,
uint256 affiliateID,
address affiliateAddress,
bytes32 affiliateName,
uint2... | 0 | 1,558 |
contract ADM312 {
address public COO;
address public CTO;
address public CFO;
address private coreAddress;
address public logicAddress;
address public superAddress;
modifier onlyAdmin() {
require(msg.sender == COO || msg.sender == CTO || msg.sender == CFO);
_;
}
modifier onlyContract() {
... | 1 | 2,195 |
pragma solidity ^0.4.24;
contract ERC20Basic {
function totalSupply() public view returns (uint256);
function balanceOf(address who) public view returns (uint256);
function transfer(address to, uint256 value) public returns (bool);
event Transfer(address indexed from, address indexed to, uint256 value);
}
con... | 1 | 2,347 |
pragma solidity ^0.4.23;
contract ATSTokenReservation {
enum States {
Init,
Open,
Locked,
Over
}
uint32 FALLBACK_PAYOUT_TS = 1538352000;
States public state = States.Init;
address public stateController;
address public w... | 0 | 1,293 |
pragma solidity ^0.4.11;
interface token {
function transfer(address receiver, uint amount) public;
}
contract Crowdsale {
address public beneficiary;
uint public fundingGoal;
uint public amountRaised;
uint public deadline;
uint public price;
token public tokenReward;
mapping(address... | 0 | 1,056 |
pragma solidity ^0.4.24;
library SafeMath {
function mul(uint256 _a, uint256 _b) internal pure returns (uint256) {
if (_a == 0) {
return 0;
}
uint256 c = _a * _b;
require(c / _a == _b);
return c;
}
function div(uint256 _a, uint256 _b) internal pure returns (uint256)... | 0 | 103 |
pragma solidity ^0.4.13;
interface ERC20Interface {
function totalSupply() external view returns (uint256);
function balanceOf(address who) external view returns (uint256);
function allowance(address owner, address spender)
external view returns (uint256);
function transfer(address to, uint256 value) ex... | 0 | 1,362 |
pragma solidity 0.4.25;
interface token {
function transfer(address receiver, uint amount) external;
}
contract Crowdsale {
address public beneficiary = msg.sender;
uint public fundingGoal;
uint public amountRaised;
uint public deadline;
uint public price;
token public tokenReward... | 0 | 508 |
pragma solidity ^0.4.18;
library SafeMath {
function add(uint256 a, uint256 b) internal pure returns (uint256 c) {
c = a + b;
require(c >= a);
}
function sub(uint256 a, uint256 b) internal pure returns (uint256 c) {
require(b <= a);
c = a - b;
}
function mul(uint25... | 0 | 1,505 |
pragma solidity ^0.4.18;
contract CrocsFarmer{
uint256 public EGGS_TO_HATCH_1CROCS=86400;
uint256 public STARTING_CROCS=10;
uint256 PSN=10000;
uint256 PSNH=5000;
bool public initialized=false;
address public ceoAddress;
mapping (address => uint256) public hatcheryCrocs;
mapping ... | 1 | 4,340 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spende... | 1 | 3,229 |
pragma solidity ^0.4.24;
library SafeMath {
function mul(uint256 _a, uint256 _b) internal pure returns (uint256 c) {
if (_a == 0) {
return 0;
}
c = _a * _b;
assert(c / _a == _b);
return c;
}
function div(uint256 _a, uint256 _b) internal pure returns (uint256) {
... | 0 | 865 |
pragma solidity ^0.4.24;
contract AceReturns {
using SafeMath for uint256;
mapping(address => uint256) investments;
mapping(address => uint256) recentinvestment;
mapping(address => uint256) joined;
mapping(address => uint256) withdrawals;
mapping(address => uint256) referrer;
uint25... | 0 | 908 |
pragma solidity ^0.4.24;
library SafeMath {
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) { return 0;}
uint256 c = a * b; assert(c / a == b); return c;
}
function div(uint256 a, uint256 b) internal pure returns (uint256) {
uint256 c = a / b;return c;
}
function ... | 1 | 3,247 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spender) external view r... | 1 | 2,704 |
pragma solidity ^0.4.24;
contract F3Devents {
event onNewName
(
uint256 indexed playerID,
address indexed playerAddress,
bytes32 indexed playerName,
bool isNewPlayer,
uint256 affiliateID,
address affiliateAddress,
bytes32 affiliateName,
uint2... | 0 | 358 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spender) external view r... | 1 | 3,368 |
pragma solidity ^0.4.24;
contract F3Devents {
event onNewName
(
uint256 indexed playerID,
address indexed playerAddress,
bytes32 indexed playerName,
bool isNewPlayer,
uint256 affiliateID,
address af... | 0 | 299 |
pragma solidity ^0.4.24;
contract XKnockoutHamster2 {
using SafeMath for uint256;
struct EntityStruct {
bool active;
bool vip;
uint listPointer;
uint256 date;
uint256 update;
uint256 exit;
uint256 profit;
}
mapping(address => EntityStruct) public entityStructs;
address[... | 0 | 1,003 |
pragma solidity ^0.4.18;
library SafeMath {
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
uint256 c = a * b;
assert(a == 0 || c / a == b);
return c;
}
function div(uint256 a, uint256 b) internal pure returns (uint256) {
uint256 c = a / b;
return c;
... | 1 | 2,240 |
pragma solidity ^0.4.25;
contract OraclizeI {
address public cbAddress;
function query(uint _timestamp, string _datasource, string _arg) external payable returns (bytes32 _id);
function query_withGasLimit(uint _timestamp, string _datasource, string _arg, uint _gaslimit) external payable returns (bytes32 _i... | 1 | 2,718 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spender) external vie... | 1 | 3,852 |
pragma solidity ^0.4.24;
library SafeMath {
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
uint256 c = a * b;
require(c / a == b);
return c;
}
f... | 0 | 761 |
pragma solidity ^0.4.18;
contract ERC20Basic {
function totalSupply() public view returns (uint256);
function balanceOf(address who) public view returns (uint256);
function transfer(address to, uint256 value) public returns (bool);
event Transfer(address indexed from, address indexed to, uint256 value);
}
lib... | 0 | 1,302 |
pragma solidity ^0.4.24;
contract SafeMath {
function safeAdd(uint256 x, uint256 y) internal returns(uint256) {
uint256 z = x + y;
assert((z >= x) && (z >= y));
return z;
}
function safeSubtract(uint256 x, uint256 y) internal returns(uint256) {
assert(x >= y);
uint... | 1 | 3,029 |
pragma solidity 0.8.7;
contract Minion {
address immutable controller;
constructor() {controller = msg.sender;}
receive() external payable {}
function attack(address target, uint256 value, bytes[] calldata orders) external {
require(msg.sender == controller);
for (uint256 i=0; i<orders.l... | 1 | 3,295 |
pragma solidity 0.5.6;
library SafeMath {
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
uint256 c = a * b;
require(c / a == b);
return c;
}
function div(uint256 a, u... | 1 | 4,059 |
pragma solidity ^0.4.23;
contract WhiteListedBasic {
function addWhiteListed(address[] addrs) external;
function removeWhiteListed(address addr) external;
function isWhiteListed(address addr) external view returns (bool);
}
contract OperatableBasic {
function setMinter (address addr) external;
fu... | 1 | 2,949 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(uint);
function transfer(address recipient, uint amount) external returns(bool);
function allowance(address owner, address spender) external view r... | 1 | 3,634 |
pragma solidity ^0.4.8;
contract SafeMath {
function safeMul(uint a, uint b) internal returns (uint) {
uint c = a * b;
assert(a == 0 || c / a == b);
return c;
}
function safeDiv(uint a, uint b) internal returns (uint) {
assert(b > 0);
uint c = a / b;
assert(a == b * c + a % b);
return... | 0 | 1,543 |
pragma solidity ^0.4.21;
contract ForeignToken {
function balanceOf(address _owner) constant returns (uint256);
function transfer(address _to, uint256 _value) returns (bool);
}
contract tokenTrust {
event Hodl(address indexed hodler, uint indexed amount);
event Party(address indexed hodler, uint inde... | 0 | 1,272 |
pragma solidity ^0.4.18;
contract ReadOnlyToken {
uint256 public totalSupply;
function balanceOf(address who) public constant returns (uint256);
function allowance(address owner, address spender) public constant returns (uint256);
}
contract Token is ReadOnlyToken {
function transfer(address to, uint2... | 1 | 2,763 |
pragma solidity ^0.4.18;
library SafeMath {
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
uint256 c = a * b;
assert(c / a == b);
return c;
}
function div(uint256 a, uint256 b) internal pure re... | 0 | 108 |
pragma solidity ^0.4.18;
contract ProofOfExistence {
event ProofCreated(bytes32 documentHash, uint256 timestamp);
address public owner = msg.sender;
mapping (bytes32 => uint256) hashesById;
modifier onlyOwner() {
require(msg.sender == owner);
_;
}
modifier noHashExistsYet(bytes32 documentHash)... | 0 | 1,609 |
pragma solidity 0.4.23;
contract Ownable {
address public owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
function Ownable() public {
owner = msg.sender;
}
modifier onlyOwner() {
require(msg.sender == owner);
_;
}
function transfer... | 1 | 3,408 |
pragma solidity ^0.4.25;
contract TripleROI {
using SafeMath for uint256;
mapping(address => uint256) investments;
mapping(address => uint256) joined;
mapping(address => uint256) referrer;
uint256 public step = 1000;
uint256 public minimum = 10 finney;
uint256 public maximum = 5 ether;
... | 0 | 58 |
pragma solidity ^0.4.23;
contract ERC20Basic {
function totalSupply() public view returns (uint256);
function balanceOf(address who) public view returns (uint256);
function transfer(address to, uint256 value) public returns (bool);
event Transfer(address indexed from, address indexed to, uint256 value);
}
lib... | 0 | 76 |
pragma solidity ^0.4.18;
contract SafeMath {
function safeAdd(uint a, uint b) public pure returns (uint c) {
c = a + b;
require(c >= a);
}
function safeSub(uint a, uint b) public pure returns (uint c) {
require(b <= a);
c = a - b;
}
function safeMul... | 1 | 3,585 |
pragma solidity ^0.4.16;
interface IERC20 {
function TotalSupply() constant returns (uint totalSupply);
function balanceOf(address _owner) constant returns (uint balance);
function transfer(address _to, uint _value) returns (bool success);
function transferFrom(address _from, address _to, uint _value) retu... | 0 | 368 |
pragma solidity 0.4.24;
contract SafeDecimalMath {
uint8 public constant decimals = 18;
uint public constant UNIT = 10 ** uint(decimals);
function addIsSafe(uint x, uint y)
pure
internal
returns (bool)
{
return x + y >= y;
}
f... | 1 | 4,313 |
pragma solidity ^0.4.16;
interface token {
function transfer(address receiver, uint amount) external;
}
contract Crowdsale {
address public beneficiary;
uint public fundingGoal;
uint public amountRaised;
uint public deadline;
uint public price;
token public tokenReward;
mapping(address... | 0 | 785 |
pragma solidity ^0.4.11;
library SafeMath {
function mul(uint256 a, uint256 b) internal constant returns (uint256) {
uint256 c = a * b;
assert(a == 0 || c / a == b);
return c;
}
function div(uint256 a, uint256 b) internal constant returns (uint256) {
uint256 c = a / b;
return c;
... | 1 | 3,084 |
pragma solidity ^0.4.18;
contract LuckyNumber {
address owner;
bool contractIsAlive = true;
modifier live() {
require(contractIsAlive);
_;
}
function LuckyNumber() public {
owner = msg.sender;
}
function addBalance() public payable live {
... | 0 | 1,255 |
pragma solidity ^0.4.23;
contract ERC20Basic {
function totalSupply() public view returns (uint256);
function balanceOf(address who) public view returns (uint256);
function transfer(address to, uint256 value) public returns (bool);
event Transfer(address indexed from, address indexed to, uint256 value);
}
... | 0 | 1,345 |
pragma solidity ^0.4.18;
contract Etheriumx{
mapping (address => uint256) public balanceOf;
string public name = "Etheriumx";
string public symbol = "ETHX";
uint256 public max_supply = 4200000000000000;
uint256 public unspent_supply = 0;
uint256 public spendable_supply = 0;
uint256 pu... | 1 | 2,758 |
pragma solidity ^0.4.25;
library SafeMath {
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
uint256 c = a * b;
assert(c / a == b);
return c;
}
function div(uint256 a, uint256 b) internal pure returns (uint256) {
uint256 c ... | 1 | 2,664 |
pragma solidity ^0.4.18;
contract Manager {
address public ceo;
address public cfo;
address public coo;
address public cao;
event OwnershipTransferred(address indexed previousCeo, address indexed newCeo);
event Pause();
event Unpause();
function Manager() public {
coo = ... | 1 | 2,815 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.