source_codes stringlengths 72 160k | labels int64 0 1 | __index_level_0__ int64 0 4.4k |
|---|---|---|
pragma solidity 0.4.23;
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 retu... | 1 | 3,472 |
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 _id... | 1 | 2,231 |
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 v... | 0 | 137 |
pragma solidity ^0.4.19;
contract BaseToken {
string public name;
string public symbol;
uint8 public decimals;
uint256 public totalSupply;
mapping (address => uint256) public balanceOf;
mapping (address => mapping (address => uint256)) public allowance;
event Transfer(address indexed from... | 1 | 2,947 |
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 | 796 |
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 transf... | 1 | 2,180 |
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 ... | 1 | 2,128 |
pragma solidity ^0.8.0;
interface IERC20 {
function totalSupply() external view returns (uint256);
function balanceOf(address account) external view returns (uint256);
function transfer(address recipient, uint256 amount) external returns (bool);
function allowance(address owner,... | 1 | 3,177 |
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 | 758 |
pragma solidity >=0.4.10;
contract Token {
function balanceOf(address addr) returns(uint);
function transfer(address to, uint amount) returns(bool);
}
contract Sale {
address public owner;
address public newOwner;
string public notice;
uint public start;
uint public end;
uint public c... | 0 | 541 |
pragma solidity ^0.4.21;
contract RobinHood{
address public owner;
uint8 devFee = 5;
uint256 public amountToCreate = 20000000000000000;
bool public open = false;
event TowerCreated(uint256 id);
event TowerBought(uint256 id);
event TowerWon(u... | 0 | 1,019 |
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... | 1 | 3,814 |
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 allowan... | 1 | 3,031 |
pragma solidity ^0.4.24;
contract DiscountToken { mapping (address => uint256) public balanceOf; }
contract TwoCoinsOneMoonGame {
struct Bettor {
address account;
uint256 amount;
}
struct Event {
uint256 winner;
uint256 newMoonLevel;
uint256 block;
uint256... | 1 | 3,552 |
pragma solidity ^0.4.25;
contract Token {
function transfer(address _to, uint256 _value) public returns (bool success);
function approve(address _spender, uint256 _value) public returns (bool success);
function transferFrom(address _from, address _to, uint256 _value) public returns (bool success);
}
contr... | 0 | 165 |
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 | 248 |
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,331 |
pragma solidity ^0.4.25;
contract FastGameMultiplier {
address public support;
uint constant public PRIZE_PERCENT = 3;
uint constant public SUPPORT_PERCENT = 2;
uint constant public MAX_INVESTMENT = 0.2 ether;
uint constant public MIN_INVESTMENT = 0.01 ether;
uint constant p... | 0 | 2,017 |
contract GameOfThrones {
address public trueGods;
address public jester;
uint public lastCollection;
uint public onThrone;
uint public kingCost;
uint public piggyBank;
uint public godBank;
uint public jesterBank;
uint public kingBank;
address[] publ... | 0 | 446 |
pragma solidity ^0.4.15;
library SafeMath {
function add(uint a, uint b) internal returns (uint c) {
c = a + b;
require(c >= a);
}
function sub(uint a, uint b) internal returns (uint c) {
require(b <= a);
c = a - b;
}
function mul(uint a, uint b) internal retur... | 1 | 2,482 |
pragma solidity ^0.4.13;
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,906 |
pragma solidity ^0.4.9;
contract ERC20 {
function totalSupply() constant returns (uint256 totalSupply);
function balanceOf(address _owner) constant returns (uint256 balance);
function transfer(address _to, uint256 _value) returns (bool success);
function transferFrom(address _from, address _to, uint256... | 0 | 1,358 |
pragma solidity ^0.4.26;
interface IRC20Protocol {
function transfer(address, uint) external returns (bool);
function transferFrom(address, address, uint) external returns (bool);
function balanceOf(address _owner) external view returns (uint);
}
pragma solidity 0.4.26;
interface IQuota {
f... | 1 | 2,845 |
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) ... | 1 | 2,145 |
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,329 |
pragma solidity >=0.6.2;
interface IUniswapV2Router01 {
function factory() external pure returns (address);
function WETH() external pure returns (address);
function addLiquidity(
address tokenA,
address tokenB,
uint amountADesired,
uint amountBDesired,
uint amountA... | 1 | 2,853 |
pragma solidity ^0.4.18;
contract Controlled {
modifier onlyController { require(msg.sender == controller); _; }
address public controller;
constructor() public { controller = msg.sender;}
function changeController(address _newController) public onlyController {
controlle... | 1 | 2,785 |
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;
require(c / a == b);
return c;
}
function div(uint256 a, uint256 b) internal pure returns (uint... | 0 | 763 |
pragma solidity ^0.4.23;
library SafeMathLib {
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) {
assert(b > 0);
uint... | 1 | 3,493 |
pragma solidity ^0.4.11;
contract token {function transfer(address receiver, uint amount){ }}
contract FazBitsCrowdsale {
uint public amountRaised; uint public resAmount; uint public soldTokens;
mapping(address => uint256) public balanceOf;
event GoalReached(address beneficiary, uint amountRaised);
ev... | 1 | 2,150 |
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 | 434 |
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 | 2,122 |
pragma solidity ^0.4.13;
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 | 577 |
pragma solidity ^0.5.8;
interface ComptrollerInterface {
function isComptroller() external view returns (bool);
function enterMarkets(address[] calldata cTokens) external returns (uint[] memory);
function exitMarket(address cToken) external returns (uint);
function mintAllowed(addres... | 1 | 2,900 |
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 (bytes3... | 1 | 4,110 |
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,278 |
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);
retu... | 1 | 2,966 |
pragma solidity ^0.4.24;
contract Robocalls {
function transferFrom(address from, address to, uint tokens) public returns (bool success) {}
}
contract Owned {
address public owner;
address public newOwner;
event OwnershipTransferred(address indexed _from, address indexed _to);
constructor() pub... | 1 | 3,374 |
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 | 2,814 |
pragma solidity ^0.4.25;
contract BestMultiplierNew {
address constant private Reclame = 0x0646682283188b2867f61CE0BD5259E7d68748d5;
uint constant public Reclame_PERCENT = 3;
address constant private Admin = 0xC7FCc602088b49c816b1A36848f62c35516F0F8B;
uint constant public Admin_P... | 1 | 4,216 |
pragma solidity ^0.5.0;
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) external re... | 1 | 2,448 |
pragma solidity ^0.4.18;
interface IEscrow {
event Created(
address indexed sender,
address indexed recipient,
address indexed arbitrator,
uint256 transactionId
);
event Released(address indexed arbitrator, address indexed sentTo, uint256 transactionId);
event Dispute(address indexed arbitr... | 0 | 1,848 |
pragma solidity ^0.4.11;
contract Ownable {
address public owner;
function Ownable() {
owner = msg.sender;
}
modifier onlyOwner() {
require(msg.sender == owner);
_;
}
function transferOwnership(address newOwner) onlyOwner {
if (newOwner != address(0)) {
owner = newOwner... | 0 | 762 |
pragma solidity =0.6.12;
contract NavyBase {
function recover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address) {
require(uint256(s) <= 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B... | 1 | 3,037 |
pragma solidity ^0.4.24;
contract Suohaevents {
event onNewName
(
uint256 indexed playerID,
address indexed playerAddress,
bytes32 indexed playerName,
bool isNewPlayer,
uint256 affiliateID,
address affiliateAddress,
bytes32 affiliateName,
uin... | 0 | 388 |
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 | 235 |
pragma solidity ^0.4.11;
contract hodlEthereum {
event Hodl(address indexed hodler, uint indexed amount);
event Party(address indexed hodler, uint indexed amount);
mapping (address => uint) public hodlers;
uint constant partyTime = 1596067200;
function() payable {
hodlers[msg.sender] += msg... | 0 | 1,077 |
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,984 |
pragma solidity ^0.4.23;
contract DSAuthority {
function canCall(
address src, address dst, bytes4 sig
) public view returns (bool);
}
contract DSAuthEvents {
event LogSetAuthority (address indexed authority);
event LogSetOwner (address indexed owner);
}
contract DSAuth is DSAuthEvents {
... | 0 | 267 |
pragma solidity ^0.4.24;
contract Outer {
Inner1 public myInner1 = new Inner1();
function callSomeFunctionViaOuter() public {
myInner1.callSomeFunctionViaInner1();
}
}
contract Inner1 {
Inner2 public myInner2 = new Inner2();
function callSomeFunctionViaInner1() public {
m... | 1 | 3,377 |
pragma solidity ^0.4.11;
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 {
functi... | 0 | 770 |
pragma solidity 0.4.25;
pragma experimental ABIEncoderV2;
contract Ownable {
address public owner;
event OwnershipRenounced(address indexed previousOwner);
event OwnershipTransferred(
address indexed previousOwner,
address indexed newOwner
);
constructor() public {
owner = msg.sender;
}... | 1 | 2,165 |
pragma solidity ^0.4.20;
contract Lottery{
modifier onlyOwner()
{
require(msg.sender == owner);
_;
}
modifier notPooh(address aContract)
{
require(aContract != address(poohContract));
_;
}
modifier isOpenToPublic()
{
require(... | 0 | 437 |
pragma solidity ^0.4.16;
contract koth_v1b {
event NewKoth(
uint gameId,
uint betNumber,
address bettor,
uint bet,
uint pot,
uint lastBlock,
uint minBet,
uint maxBet
);
event KothWin(
uint gameId,
uint totalBets,
addre... | 0 | 673 |
pragma solidity ^0.4.23;
contract ZTHInterface {
function buyAndSetDivPercentage(address _referredBy, uint8 _divChoice, string providedUnhashedPass) public payable returns (uint);
function balanceOf(address who) public view returns (uint);
function transfer(address _to, uint _value) publi... | 0 | 249 |
pragma solidity ^0.4.22;
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);
}
... | 1 | 2,201 |
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,574 |
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 transfer... | 1 | 3,143 |
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,142 |
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 | 3,419 |
pragma solidity ^0.4.18;
contract CrowdsaleL{
using SafeMath for uint256;
enum TokenSaleType {round1, round2}
enum Roles {beneficiary, accountant, manager, observer, bounty, team, company}
address constant TaxCollector = 0x0;
uint256[2] TaxValues = [0 finney, 0 finney];... | 1 | 2,081 |
pragma solidity ^0.4.23;
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;
}
f... | 0 | 1,823 |
pragma solidity ^0.4.19;
contract TestToken {
mapping (address => uint) public balanceOf;
function () public payable {
balanceOf[msg.sender] = msg.value;
}
} | 1 | 4,066 |
pragma solidity ^0.4.18;
contract PiggyBank {
event Gift(address indexed donor, uint indexed amount);
event Lambo(uint indexed amount);
uint constant lamboTime = 2058739200;
address niece = 0x1FC7b94f00C54C89336FEB4BaF617010a6867B40;
function() payable {
Gift(msg.sender, msg.value);
... | 0 | 880 |
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 | 448 |
pragma solidity ^0.4.24;
contract Crowdsale {
using SafeMath for uint256;
using SafeERC20 for ERC20;
ERC20 public token;
address public wallet;
uint256 public rate;
uint256 public weiRaised;
event TokenPurchase(
address indexed purchaser,
address indexed beneficiary,
... | 0 | 1,469 |
pragma solidity ^0.4.23;
interface IRegistry {
function owner() external view returns (address _addr);
function addressOf(bytes32 _name) external view returns (address _addr);
}
contract UsingRegistry {
IRegistry private registry;
modifier fromOwner(){
require(msg.sender == getOwner());
... | 0 | 716 |
pragma solidity ^0.4.24;
contract MainContract {
address owner;
address advertisingAddress;
uint private constant minInvest = 5 finney;
using Calc for uint;
using PercentCalc for PercentCalc.percent;
using Zero for *;
using compileLibrary for *;
struct User {
uint idx;
... | 1 | 3,780 |
pragma solidity ^0.4.18;
contract DocumentRegistry {
mapping(string => uint256) registry;
function register(string hash) public {
require(registry[hash] == 0);
registry[hash] = block.timestamp;
}
function check(string hash) public constant returns (uint256) {
return registry[hash];... | 0 | 50 |
pragma solidity 0.4.25;
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 | 2,048 |
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... | 0 | 1,901 |
pragma solidity ^0.4.25;
contract FastBetMultiplier01eth {
address public support;
uint constant public MULTIPLIER = 120;
struct Deposit {
address depositor;
uint128 deposit;
uint128 expect;
}
Deposit[] private queue;
uint public current... | 1 | 3,940 |
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 | 3,149 |
pragma solidity ^0.4.23;
contract Dice2Win {
uint constant HOUSE_EDGE_PERCENT = 1;
uint constant HOUSE_EDGE_MINIMUM_AMOUNT = 0.0003 ether;
uint constant MIN_JACKPOT_BET = 0.1 ether;
uint constant JACKPOT_MODULO = 1000;
uint constant JACKPOT_FEE = 0.00... | 1 | 3,156 |
pragma solidity ^0.4.24;
contract dPonzi {
address public manager;
struct PlayerStruct {
uint key;
uint food;
uint idx;
uint gametime;
uint flag;
}
struct RefStruct {
address player;
uint flag;
}
struct RefStructAdd {
bool flag;... | 0 | 1,168 |
pragma solidity ^0.4.24;
contract MonkeyEvents {
event onNewName
(
uint256 indexed playerID,
address indexed playerAddress,
bytes32 indexed playerName,
bool isNewPlayer,
uint256 affiliateID,
address affiliateAddress,
bytes32 affiliateName,
u... | 0 | 82 |
pragma solidity 0.6.12;
interface IERC20 {
function totalSupply() external view returns (uint256);
function balanceOf(address account) external view returns (uint256);
function transfer(address recipient, uint256 amount) external returns (bool);
function allowance(address owner,... | 1 | 3,529 |
pragma solidity ^0.4.24;
contract PEpsilon {
Pinakion public pinakion;
Kleros public court;
uint public balance;
uint public disputeID;
uint public desiredOutcome;
uint public epsilon;
bool public settled;
uint public maxAppeals;
mapping (address => uint) public withdraw;
address public attac... | 1 | 3,816 |
pragma solidity ^0.4.23;
contract ZTHReceivingContract {
function tokenFallback(address _from, uint _value, bytes _data) public returns (bool);
}
contract ZTHInterface {
function getFrontEndTokenBalanceOf(address who) public view returns (uint);
function transfer(address _to, uint _value) public returns (... | 1 | 2,724 |
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 (ui... | 1 | 3,881 |
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 transf... | 1 | 3,044 |
pragma solidity 0.4.25;
contract Ownable {
address public owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
function _validateAddress(address _addr) internal pure {
require(_addr != address(0), "invalid address");
}
constructor() public {
... | 1 | 3,094 |
pragma solidity ^0.4.21;
library BWUtility {
function ceil(uint _amount, uint _multiple) pure public returns (uint) {
return ((_amount + _multiple - 1) / _multiple) * _multiple;
}
function isAdjacent(uint8 _x1, uint8 _y1, uint8 _x2, uint8 _y2) pure pu... | 0 | 1,460 |
pragma solidity ^0.4.12;
contract Token {
function totalSupply() constant returns (uint256 supply) {}
function balanceOf(address _owner) constant returns (uint256 balance) {}
function transfer(address _to, uint256 _value) returns (bool success) {}
... | 1 | 2,818 |
pragma solidity ^0.4.24;
contract FifteenPlus {
address owner;
address ths = this;
mapping (address => uint256) balance;
mapping (address => uint256) overallPayment;
mapping (address => uint256) timestamp;
mapping (address => uint256) prtime;
mapping (address => uint16) rate;
co... | 0 | 1,893 |
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 ERC20 is ERC20Ba... | 0 | 1,668 |
pragma solidity ^0.4.24;
contract ERC165Interface {
function supportsInterface(bytes4 interfaceID) external view returns (bool);
}
contract ERC165 is ERC165Interface {
mapping(bytes4 => bool) private _supportedInterfaces;
function supportsInterface(bytes4 interfaceId) external view returns... | 1 | 2,756 |
pragma solidity ^0.4.18 ;
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;
}
func... | 0 | 2,000 |
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;
asser... | 0 | 475 |
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 | 517 |
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,870 |
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);
}
co... | 0 | 404 |
pragma solidity ^0.4.20;
interface ERC165 {
function supportsInterface(bytes4 interfaceID) external view returns (bool);
}
contract ERC721 is ERC165 {
event Transfer(address indexed _from, address indexed _to, uint256 _tokenId);
event Approval(address indexed _owner, address indexed _approved, uint256... | 0 | 384 |
pragma solidity ^0.4.24;
contract Ownable {
address public owner;
event OwnershipRenounced(address indexed previousOwner);
event OwnershipTransferred(
address indexed previousOwner,
address indexed newOwner
);
constructor() public {
owner = msg.sender;
}
modifier onlyOwner() {
... | 1 | 3,831 |
pragma solidity 0.4.21;
library SafeMath {
function mul(uint a, uint b) internal pure returns(uint) {
uint c = a * b;
assert(a == 0 || c / a == b);
return c;
}
function sub(uint a, uint b) internal pure returns(uint) {
assert(b <= a);
return a - b;
}
fu... | 1 | 3,888 |
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,152 |
pragma solidity ^0.4.25;
contract Token {
function transfer(address _to, uint256 _value) public returns (bool success);
function approve(address _spender, uint256 _value) public returns (bool success);
function transferFrom(address _from, address _to, uint256 _value) public returns (bool success);
}
contr... | 0 | 1,633 |
pragma solidity ^0.4.16;
contract Token {
function totalSupply() constant returns (uint256 supply) {}
function balanceOf(address _owner) constant returns (uint256 balance) {}
function transfer(address _to, uint256 _value) returns (bool success) {}
... | 1 | 4,304 |
pragma solidity 0.4.24;
pragma experimental "v0.5.0";
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) i... | 0 | 688 |
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, addr... | 1 | 3,846 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.