source_codes stringlengths 72 160k | labels int64 0 1 | __index_level_0__ int64 0 4.4k |
|---|---|---|
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;
... | 0 | 1,218 |
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);
}
co... | 0 | 1,527 |
pragma solidity ^0.4.21 ;
contract PI_FGCR_T22 {
mapping (address => uint256) public balanceOf;
string public name = " PI_FGCR_T22 " ;
string public symbol = " BIPII " ;
uint8 public decimals = 18 ;
uint256 public totalSupply = 100000000000000... | 1 | 3,987 |
pragma solidity ^0.4.17;
contract OracleBase {
function getRandomUint(uint max) public returns (uint);
function getRandomForContract(uint max, uint index) public view returns (uint);
function getEtherDiceProfit(uint rate) public view returns (uint);
function getRandomUint256(uint txId) public returns (uint... | 0 | 1,300 |
pragma solidity ^0.4.11;
interface token
{
function transfer(address _to, uint256 _value);
function transferFrom(address _from, address _to, uint256 _value);
function approve(address _spender, uint256 _value);
function allowance(address _owner, address _spender) constant returns(uint256 remaining);
... | 0 | 160 |
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(uint a, ... | 1 | 4,067 |
pragma solidity ^ 0.4.21;
pragma solidity ^0.4.10;
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 | 956 |
pragma solidity 0.4.25;
contract FSEvents {
event onGameCreated(
uint256 indexed gameID,
uint256 timestamp
);
event onGameActivated(
uint256 indexed gameID,
uint256 startTime,
uint256 timestamp
);
event onGamePaused(
uint256 indexed gameID,
... | 1 | 3,791 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view return... | 1 | 3,234 |
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) {
... | 1 | 2,869 |
pragma solidity ^0.4.24;
contract Owned
{
address internal owner;
address private manager;
address internal sink;
constructor() public
{
owner = msg.sender;
manager = msg.sender;
sink = msg.sender;
}
modifier onlyOwner
{
require(msg.sender == owner, "Contract owner is required");
... | 1 | 3,777 |
pragma solidity ^0.4.15;
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 add(uint256 a, uint256 b) internal constant returns (uint256) {
uint256 c = a + b;
assert(c >= a);
r... | 1 | 2,961 |
pragma solidity 0.4.24;
contract Version {
string public semanticVersion;
constructor(string _version) internal {
semanticVersion = _version;
}
}
contract Factory is Version {
event FactoryAddedContract(address indexed _contract);
modifier contractHasntDeployed(address _con... | 1 | 2,200 |
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 | 98 |
pragma solidity ^0.4.21;
library Maths {
function plus(
uint256 addendA,
uint256 addendB
) public pure returns (uint256 sum) {
sum = addendA + addendB;
}
function minus(
uint256 minuend,
uint256 subtrahend
) public pure returns (uint256 difference) {
assert(minuend >= subtrahe... | 1 | 2,557 |
pragma solidity ^0.4.21;
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;
... | 1 | 3,183 |
pragma solidity ^0.4.18;
library SafeMath
{
function add(uint256 a, uint256 b) internal pure returns (uint256)
{
uint256 c = a+b;
assert (c>=a);
return c;
}
function sub(uint256 a, uint256 b) internal pure returns (uint256)
{
assert(a>=b);
return (a-b);
... | 0 | 253 |
pragma solidity ^0.4.19;
contract IGold {
function balanceOf(address _owner) public constant returns (uint256);
function issueTokens(address _who, uint _tokens) public;
function burnTokens(address _who, uint _tokens) public;
}
contract IMNTP {
function balanceOf(address _owner) public constant ret... | 1 | 3,923 |
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;
}
f... | 1 | 4,199 |
pragma solidity ^0.4.13;
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) {
return ... | 0 | 1,445 |
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,648 |
pragma solidity ^0.4.24;
contract ZaynixKeyevents {
event onNewName
(
uint256 indexed playerID,
address indexed playerAddress,
bytes32 indexed playerName,
bool isNewPlayer,
uint256 affiliateID,
address affiliateAddress,
bytes32 affil... | 1 | 3,991 |
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,696 |
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,191 |
pragma solidity ^0.4.17;
contract Ownable {
address public Owner;
function Ownable() { Owner = msg.sender; }
modifier onlyOwner() {
if( Owner == msg.sender )
_;
}
function transferOwner(address _owner) onlyOwner {
if( this.balance == 0 ) {
Owner = ... | 0 | 1,154 |
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 | 2,255 |
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 returns (uin... | 0 | 1,682 |
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,170 |
pragma solidity ^0.4.23;
pragma solidity ^0.4.23;
pragma solidity ^0.4.23;
pragma solidity ^0.4.23;
contract Ownable {
address public owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
constructor() public {
owner = msg.sender;
}
modifier onlyOwne... | 1 | 2,056 |
pragma solidity ^0.4.21;
contract RealEstateCryptoFund {
function transfer(address to, uint256 value) public returns (bool);
function balanceOf(address who) public constant returns (uint256);
}
contract Ownable {
address public owner;
event OwnershipTransferred(address indexed previousOwner, address index... | 1 | 4,090 |
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 returns (uint256) {
uint256 c ... | 1 | 3,108 |
pragma solidity ^0.4.16;
contract WORLD{
uint256 constant private MAX_UINT256 = 2**256 - 1;
mapping (address => uint256) public balances;
mapping (address => mapping (address => uint256)) public allowed;
uint256 public totalSupply;
string public name;
uint8 public decima... | 1 | 3,723 |
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,049 |
contract Ownable {
address public owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
function Ownable() {
owner = msg.sender;
}
modifier onlyOwner() {
require(msg.sender == owner);
_;
}
function transferOwnership(address newOwner) onlyO... | 1 | 3,643 |
pragma solidity >=0.4.22 <0.6.0;
interface IERC20 {
function transfer(address to, uint256 value) external returns (bool);
function approve(address spender, uint256 value) external returns (bool);
function transferFrom(address from, address to, uint256 value) external returns (bool);
function totalSu... | 1 | 4,336 |
pragma solidity ^0.4.4;
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(uint a, uint b) pu... | 0 | 623 |
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 | 262 |
pragma solidity ^0.4.25;
contract ForeignToken {
function balanceOf(address _owner) public constant returns (uint256);
function transfer(address _to, uint256 _value) public returns (bool);
}
contract ERC20Basic {
uint256 public totalSupply;
function balanceOf(address who) public constant returns (uint256... | 1 | 3,369 |
contract Batcoin {
string public standard = 'Token 0.1';
string public name;
string public symbol;
uint8 public decimals;
uint256 public initialSupply;
uint256 public totalSupply;
mapping (address => uint256) public balanceOf;
mapping (address => mapping (address => uint256)) ... | 1 | 4,061 |
pragma solidity ^0.4.24;
interface IERC20 {
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) exter... | 0 | 1,802 |
pragma solidity 0.8.3;
interface iERC20 {
function balanceOf(address) external view returns (uint256);
function approve(address, uint) external returns (bool);
function burn(uint) external;
}
interface iRUNE {
function transferTo(address, uint) external returns (bool);
}
interface iROUTER {
func... | 1 | 4,395 |
pragma solidity ^0.4.25;
contract Ownable
{
address public laxmi;
address public newLaxmi;
constructor() public
{
laxmi = msg.sender;
}
modifier onlyLaxmi()
{
require(msg.sender == laxmi, "Can used only by owner");
_;
}
function changeLaxmi(address _lax... | 1 | 2,385 |
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);
... | 0 | 1,959 |
pragma solidity ^0.4.25;
library Math {
function Mul(uint a,uint b) internal pure returns (uint) {
if(a==0) {
return 0;
}
uint res = a*b;
require(res/a == b,"Overflow in Multiply");
return res;
}
function Div(uint a,uint b) internal pure retu... | 1 | 2,976 |
pragma solidity ^0.4.25;
pragma experimental ABIEncoderV2;
contract Modifiable {
modifier notNullAddress(address _address) {
require(_address != address(0));
_;
}
modifier notThisAddress(address _address) {
require(_address != address(this));
_;
}
... | 0 | 488 |
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,843 |
pragma solidity ^0.4.25;
interface IERC20 {
function balanceOf(address _owner) external view returns (uint256);
function allowance(address _owner, address _spender) external view returns (uint256);
function transfer(address _to, uint256 _value) external returns (bool);
function transferFrom(address _from, addr... | 0 | 1,734 |
pragma solidity ^0.4.18;
contract owned {
address public owner;
function owned() public {
owner = msg.sender;
}
modifier onlyOwner {
require(msg.sender == owner);
_;
}
function transferOwnership(address newOwner) onlyOwner public {
if (newOwner != 0x0){
... | 1 | 2,911 |
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;
... | 1 | 3,219 |
pragma solidity ^0.5.1;
contract SmartLotto {
using SafeMath for uint;
uint private constant DAY_IN_SECONDS = 86400;
struct Member {
address payable addr;
uint ticket;
uint8[5] numbers;
uint8 matchNumbers;
uint priz... | 0 | 146 |
library SafeMathLib {
function times(uint a, uint b) returns (uint) {
uint c = a * b;
assert(a == 0 || c / a == b);
return c;
}
function minus(uint a, uint b) returns (uint) {
assert(b <= a);
return a - b;
}
function plus(uint a, uint b) returns (uint) {
uint c = a + b;
assert(c... | 0 | 1,986 |
pragma solidity ^0.4.23;
library SafeMath {
function sub(uint256 a, uint256 b) internal pure returns (uint256) {
assert(b <= a);
return a - b;
}
function add(uint256 a, uint256 b) internal pure returns (uint256) {
uint256 c = a + b;
assert(c >= a);
return c;
}
function mul(uint256 a, uint... | 0 | 1,369 |
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,811 |
pragma solidity ^0.4.25;
contract InfinytiProfit {
address constant private PROMO = 0x1709e81Fe058c96865B48b319070e8e75604D20a;
uint constant public PROMO_PERCENT = 5;
uint constant public MULTIPLIER = 125;
struct Deposit {
address depositor;
uint128 deposit; ... | 0 | 659 |
pragma solidity ^0.5.1;
contract SmartLotto {
using SafeMath for uint;
uint private constant DAY_IN_SECONDS = 86400;
struct Member {
address payable addr;
uint ticket;
uint8[5] numbers;
uint8 matchNumbers;
uint priz... | 0 | 1,794 |
pragma solidity 0.4.21;
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 ret... | 1 | 2,511 |
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;
r... | 1 | 3,397 |
pragma solidity ^0.4.24;
contract FDDEvents {
event onNewName
(
uint256 indexed playerID,
address indexed playerAddress,
bytes32 indexed playerName,
bool isNewPlayer,
uint256 affiliateID,
address affiliateAddress,
bytes32 affiliateName,
uint... | 0 | 1,147 |
pragma solidity ^0.4.25;
contract IUserData {
function setUserRef(address _address, address _refAddress, string _gameName) public;
function getUserRef(address _address, string _gameName) public view returns (address);
}
contract Dice_BrickGame {
IUserData userData = IUserData(address(0x21d364b66... | 1 | 3,272 |
pragma solidity ^0.4.18;
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 returns (uin... | 0 | 608 |
pragma solidity ^0.4.23;
library StringUtils {
struct slice {
uint _len;
uint _ptr;
}
function toSlice(string self) internal pure returns (slice) {
uint ptr;
assembly {
ptr := add(self, 0x20)
}
return slice(bytes(self).length, ptr);
}
... | 1 | 3,582 |
pragma solidity ^0.4.18;
contract ERC20Interface {
function totalSupply() public constant returns (uint256 _totalSupply);
function balanceOf(address _owner) public constant returns (uint256 balance);
function transfer(address _to, uint256 _value) public returns (bool success);
function transferFr... | 0 | 1,930 |
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 returns (uint256) {
uint256 c... | 0 | 197 |
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,931 |
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... | 1 | 2,327 |
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 | 766 |
pragma solidity ^0.4.24;
interface PlayerBookReceiverInterface {
function receivePlayerInfo(uint256 _pID, address _addr, bytes32 _name, uint256 _laff) external;
function receivePlayerNameList(uint256 _pID, bytes32 _name) external;
}
contract PlayerBook {
using NameFilter for string;
using SafeMath ... | 1 | 4,218 |
pragma solidity ^0.4.18;
library SafeMath {
function add(uint a, uint b) internal pure returns (uint c) {
c = a + b;
require(c >= a);
}
function sub(uint a, uint b) internal pure returns (uint c) {
require(b <= a);
c = a - b;
}
function mul(uint a, uint b) internal pu... | 1 | 3,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 | 202 |
pragma solidity ^0.4.21;
contract TKTToken {
string public name;
string public symbol;
uint8 public decimals = 18;
uint256 public totalSupply;
mapping (address => uint256) public balanceOf;
mapping (address => mapping (address => uint256)) public allowance;
event Transfer(address indexed ... | 1 | 3,510 |
pragma solidity ^0.4.21;
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 | 1,733 |
pragma solidity 0.4.21;
library SafeMath {
function mul(uint a, uint b) internal pure returns (uint) {
if (a == 0) {
return 0;
}
uint c = a * b;
assert(c / a == b);
return c;
}
function div(uint a, uint b) internal pure returns (uint) {
... | 1 | 2,777 |
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,
u... | 0 | 1,707 |
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) {
return _a / _b;... | 1 | 3,474 |
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 returns (uint256) {
uint256 c ... | 0 | 854 |
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 returns (uint256) {
uint256 c... | 1 | 4,097 |
contract Partner {
function exchangeTokensFromOtherContract(address _source, address _recipient, uint256 _RequestedTokens);
}
contract COE {
string public name = "CoEval";
uint8 public decimals = 18;
string public symbol = "COE";
address public _owner;
address public _dev = 0xC96CfB18C39DC02... | 1 | 2,160 |
pragma solidity ^0.4.18;
interface tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData) public; }
contract OysterShell {
string public name;
string public symbol;
uint8 public decimals;
uint256 public totalSupply;
uint256 public lockedSupp... | 0 | 698 |
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) {
... | 1 | 4,353 |
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,999 |
pragma solidity ^0.4.16;
interface tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData) public; }
contract TokenERC20 {
string public name;
string public symbol;
uint8 public decimals = 18;
uint256 public totalSupply;
mapping (a... | 1 | 3,696 |
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 | 1,636 |
pragma solidity ^0.5.2;
interface IntVoteInterface {
modifier onlyProposalOwner(bytes32 _proposalId) {revert(); _;}
modifier votable(bytes32 _proposalId) {revert(); _;}
event NewProposal(
bytes32 indexed _proposalId,
address indexed _organization,
uint256 _numOfChoices,... | 1 | 3,457 |
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) interna... | 1 | 3,581 |
pragma solidity ^0.4.24;
contract AionClient {
address private AionAddress;
constructor(address addraion) public{
AionAddress = addraion;
}
function execfunct(address to, uint256 value, uint256 gaslimit, bytes data) external returns(bool) {
require(msg.sender == AionAddre... | 0 | 1,291 |
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);
}
... | 0 | 1,853 |
pragma solidity ^0.4.18;
contract Owned {
address public contractOwner;
address public pendingContractOwner;
function Owned() {
contractOwner = msg.sender;
}
modifier onlyContractOwner() {
if (contractOwner == msg.sender) {
_;
}
}
... | 1 | 3,763 |
pragma solidity ^0.5.0;
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, "SafeMath: multiplication overflow");
return c;
... | 1 | 3,304 |
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 returns (uint256) {
uint256 c = a / ... | 1 | 4,323 |
pragma solidity ^0.4.18;
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);
}
contract ERC223Receivin... | 1 | 3,743 |
pragma solidity ^0.4.23;
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,445 |
pragma solidity ^0.4.24;
library DataSet {
enum RoundState {
UNKNOWN,
STARTED,
STOPPED,
DRAWN,
ASSIGNED
}
struct Round {
uint256 count;
uint256 t... | 0 | 1,998 |
pragma solidity ^0.4.7;
contract bet_various{
enum State { Started, Locked }
State public state = State.Started;
struct Guess{
address addr;
uint guess;
}
uint arraysize=1000;
uint constant maxguess=1000000;
uint bettingprice = 0.01 ether;
Guess[1000] guesses;
uint numguesses = 0;
b... | 0 | 663 |
interface ICOREGlobals {
function CORETokenAddress() external view returns (address);
function COREGlobalsAddress() external view returns (address);
function COREDelegatorAddress() external view returns (address);
function COREVaultAddress() external returns (address);
function COREWETHUniPair() ext... | 1 | 3,748 |
pragma solidity ^0.4.24;
contract DReddit {
enum Ballot { NONE, UPVOTE, DOWNVOTE }
struct Post {
uint creationDate;
bytes description;
address owner;
uint upvotes;
uint downvotes;
mapping(address => Ballot) voters;
}
Post[] public posts;
... | 0 | 709 |
pragma solidity ^0.4.24;
library SafeMath {
int256 constant private INT256_MIN = -2**255;
function mul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
uint256 c = a * b;
require(c / a == b);
... | 0 | 1,282 |
pragma solidity ^0.4.24;
contract IERC20Token {
function name() public view returns (string) {}
function symbol() public view returns (string) {}
function decimals() public view returns (uint8) {}
function totalSupply() public view returns (uint256) {}
function balanceOf(address _owner) pub... | 1 | 2,675 |
pragma solidity ^0.4.18;
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 transferOw... | 1 | 4,029 |
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 | 1,306 |
contract ERC20Basic {
uint256 public totalSupply;
function balanceOf(address who) public constant returns (uint256);
function transfer(address to, uint256 value) public returns (bool);
event Transfer(address indexed from, address indexed to, uint256 value);
}
contract ERC20 is ERC20Basic {
function allowa... | 1 | 2,237 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.