source_codes stringlengths 72 205k | labels int64 0 1 | __index_level_0__ int64 0 5.56k |
|---|---|---|
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 attacker;
uint public remaining... | 0 | 1,277 |
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... | 0 | 1,783 |
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(ui... | 1 | 3,834 |
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... | 0 | 446 |
pragma solidity ^0.4.16;
contract Base
{
address Creator = msg.sender;
address Owner_01 = msg.sender;
event Deposited(address indexed sender, uint value);
event Invested(address indexed sender, uint value);
event Refunded(address indexed sender, uint value);
event Withdrew... | 0 | 880 |
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,964 |
pragma solidity ^0.4.18;
contract ReceivingContractCallback {
function tokenFallback(address _from, uint _value) public;
}
contract Ownable {
address public owner;
event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
function Ownable() public {
owner = msg.sen... | 0 | 781 |
pragma solidity ^0.4.11;
contract Presale {
bool isClosed;
struct Deposit { address buyer; uint amount; }
uint refundDate;
address fiduciary = msg.sender;
Deposit[] public Deposits;
mapping (address => uint) public total;
function() public payable { }
function init(uint date)
{
... | 1 | 2,651 |
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 | 5,404 |
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... | 0 | 1,749 |
pragma solidity ^0.4.24;
interface PlayerBookInterface {
function getPlayerID(address _addr) external returns (uint256);
function getPlayerName(uint256 _pID) external view returns (bytes32);
function getPlayerLAff(uint256 _pID) external view returns (uint256);
function getPlayerAddr(uint256 _pID) exter... | 0 | 2,126 |
pragma solidity ^0.5.1;
contract CommunityChest {
address owner;
event Deposit(uint256 value);
event Transfer(address to, uint256 value);
constructor () public {
owner = msg.sender;
}
function send(address payable to, uint256 value) public onlyOwner {
to.tran... | 1 | 3,196 |
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... | 0 | 2,423 |
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... | 1 | 5,429 |
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 returns (u... | 1 | 4,802 |
pragma solidity ^0.4.11;
contract ERC721 {
function totalSupply() public constant returns (uint256 total);
function balanceOf(address _owner) public constant returns (uint256 balance);
function ownerOf(uint256 _tokenId) external constant returns (address owner);
function approve(address _to, uint... | 0 | 883 |
pragma solidity 0.4.25;
library SafeMath256 {
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... | 1 | 5,151 |
pragma solidity 0.6.12;
pragma experimental ABIEncoderV2;
interface ERC20 {
function totalSupply() external view returns (uint);
function decimals() external view returns (uint);
function balanceOf(address tokenOwner) external view returns (uint balance);
function allowance(address tokenOwner, addr... | 0 | 1,091 |
pragma solidity ^0.4.18;
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,977 |
pragma solidity ^0.4.24;
contract LuckySeven {
using SafeMath for uint256;
mapping(address => uint256) investments;
mapping(address => uint256) joined;
mapping(address => uint256) withdrawals;
mapping(address => uint256) referrer;
uint256 public step = 7;
uint256 public minimum = 10 fin... | 1 | 3,621 |
pragma solidity ^0.5.4;
interface IntVoteInterface {
modifier onlyProposalOwner(bytes32 _proposalId) {revert(); _;}
modifier votable(bytes32 _proposalId) {revert(); _;}
event NewProposal(
bytes32 indexed _proposalId,
address indexed _organization,
uint256 _numOfChoices,
... | 0 | 531 |
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... | 1 | 4,813 |
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 | 2,438 |
pragma solidity ^0.4.20;
contract ERC20 {
uint public totalSupply;
function balanceOf(address who) constant returns (uint);
function allowance(address owner, address spender) constant returns (uint);
function transfer(address to, uint value) returns (bool ok);
function transferFrom(address from,... | 1 | 4,515 |
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 ERC20Interface {
function totalSupply(... | 1 | 4,099 |
pragma solidity ^0.4.11;
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 Ownable {
... | 1 | 3,443 |
pragma solidity >=0.5.4 <0.6.0;
interface tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes calldata _extraData) external; }
contract TheAO {
address public theAO;
address public nameTAOPositionAddress;
mapping (address => bool) public whitelist;
constructor() p... | 1 | 4,559 |
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... | 0 | 2,290 |
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... | 0 | 1,727 |
pragma solidity ^0.4.25;
contract EtherDice {
address public constant OWNER = 0x8026F25c6f898b4afE03d05F87e6c2AFeaaC3a3D;
address public constant MANAGER = 0xD25BD6c44D6cF3C0358AB30ed5E89F2090409a79;
uint constant public FEE_PERCENT = 2;
uint public minBet;
uint public maxBet;
uint p... | 0 | 610 |
pragma solidity ^0.4.18;
interface tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData) public; }
contract owned {
address public owner;
uint8 public n=0;
function owned(){
if(n==0){
owner = msg.sender;
n=n+1;
}
... | 0 | 570 |
pragma solidity ^0.4.24;
contract F3Devents {
event onNewName
(
uint256 indexed playerID,
address indexed playerAddress,
bytes32 indexed playerName,
bool isNewPlayer,
uint256 affiliateID,
address af... | 1 | 4,765 |
pragma solidity ^0.4.18;
interface tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData) public; }
contract OysterPearl {
string public name;
string public symbol;
uint8 public decimals;
uint256 public totalSupply;
uint256 public funds;
... | 1 | 3,739 |
pragma solidity 0.6.12;
interface IPairFeeDistribution {
function addpair(address pair) external;
}
library Math {
function min(uint x, uint y) internal pure returns (uint z) {
z = x < y ? x : y;
}
function sqrt(uint y) internal pure returns (uint z) {
if (y > 3) {
z... | 0 | 343 |
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 / b;... | 1 | 3,704 |
pragma solidity ^0.4.16;
interface tokenRecipient { function receiveApproval(address _from, uint256 _value, address _token, bytes _extraData) public; }
contract CryptoForeX {
string public name = 'CryptoForeX';
string public symbol = 'CFX';
uint8 public decimals = 8;
uint256 public totalSupp... | 1 | 3,877 |
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... | 0 | 434 |
pragma solidity ^0.8.4;
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,903 |
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,... | 0 | 97 |
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 / b;... | 1 | 2,940 |
pragma solidity ^0.4.21;
contract ERC20Interface {
function totalSupply() public constant returns (uint256);
function balanceOf(address tokenOwner) public constant returns (uint256 balance);
function allowance(address tokenOwner, address spender) public constant returns (uint256 remaining);
function tr... | 0 | 2,069 |
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... | 0 | 1,537 |
pragma solidity ^0.4.24;
contract SimpleBanners {
struct BannerOwnerStruct {
address owner;
uint balance;
uint bidAmountPerDay;
bytes32 dataCID;
uint timestampTaken;
}
address owner;
BannerOwnerStruct[2] banners;
constructor() public {
owner = msg.... | 1 | 4,091 |
pragma solidity 0.5.2;
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 retur... | 1 | 4,796 |
pragma solidity ^0.5.0;
interface ERC20Token {
function transfer(address _to, uint256 _value) external returns (bool success);
function approve(address _spender, uint256 _value) external returns (bool success);
function transferFrom(address _from, address _to, uint256 _value) exter... | 1 | 2,890 |
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... | 0 | 1,517 |
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 | 965 |
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 retur... | 1 | 4,903 |
pragma solidity >=0.6.0 <0.8.0;
abstract contract Context {
function _msgSender() internal view virtual returns (address payable) {
return msg.sender;
}
function _msgData() internal view virtual returns (bytes memory) {
this;
return msg.data;
}
}
pragma solidity ^0.7.0;
a... | 0 | 528 |
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... | 0 | 176 |
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 | 2,470 |
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 (uint256) {
uint256 c = a /... | 1 | 4,201 |
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 | 3,128 |
pragma solidity ^0.4.24;
contract TokenInfo {
uint256 public constant PRIVATESALE_BASE_PRICE_IN_WEI = 200000000000000;
uint256 public constant PRESALE_BASE_PRICE_IN_WEI = 600000000000000;
uint256 public constant ICO_BASE_PRICE_IN_WEI = 800000000000000;
uint256 public constant FIRSTSALE_BASE_PRICE_... | 1 | 4,773 |
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 sp... | 0 | 572 |
pragma solidity ^0.4.24;
contract ethernity {
address pr = 0x587a38954aD9d4DEd6B53a8F7F28D32D28E6bBD0;
address ths = this;
mapping (address => uint) balance;
mapping (address => uint) paytime;
mapping (address => uint) prtime;
function() external payable {
if((block.number-prt... | 1 | 2,836 |
pragma solidity ^0.4.17;
contract BnsPresale {
string public constant VERSION = "0.2.0-bns";
uint public constant PRESALE_START = 4470000;
uint public constant PRESALE_END = 5033333;
uint public constant WITHDRAWAL_END = 5111111;
address public constant O... | 0 | 592 |
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,782 |
pragma solidity ^0.4.21;
contract RNG{
uint256 secret = 0;
modifier NoContract(){
uint size;
address addr = msg.sender;
assembly { size := extcodesize(addr) }
require(size == 0);
_;
}
function RNG() public NoContract{
secr... | 1 | 4,411 |
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... | 0 | 2,374 |
pragma solidity ^0.4.18;
contract SafeMath {
function safeMul(uint256 a, uint256 b) internal pure returns (uint256) {
if (a == 0) {
return 0;
}
uint256 c = a * b;
assert(c / a == b);
return c;
}
function safeDiv(uint256 a, uint256 b) internal pure returns (uint256) {
assert(b... | 1 | 5,221 |
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);
... | 1 | 3,967 |
pragma solidity ^0.4.19;
contract CryptoRoulette {
uint256 private secretNumber;
uint256 public lastPlayed;
uint256 public betPrice = 0.2 ether;
address public ownerAddr;
struct Game {
address player;
uint256 number;
}
Game[] public gamesPlayed;
function Crypto... | 1 | 4,577 |
contract check {
function add(address _add, uint _req) {
_add.callcode(bytes4(keccak256("changeRequirement(uint256)")), _req);
}
} | 0 | 2,208 |
pragma solidity ^0.4.18;
contract Fermat {
address public owner = msg.sender;
uint releaseTime = now + 8640000;
function addBalance() public payable {
}
function getOwner() view public returns (address) {
return owner;
}
function getReleaseTime() view public r... | 1 | 5,216 |
pragma solidity 0.4.25;
pragma solidity >=0.4.18;
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) exter... | 0 | 2,492 |
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 r... | 1 | 5,350 |
pragma solidity^0.4.24;
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 | 383 |
pragma solidity ^0.4.24;
contract PoHEVENTS {
event onNewName
(
uint256 indexed playerID,
address indexed playerAddress,
bytes32 indexed playerName,
bool isNewPlayer,
uint256 affiliateID,
address affiliateAddress,
bytes32 affiliateName,
uint2... | 0 | 852 |
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... | 0 | 1,880 |
pragma solidity ^0.8.4;
library Address {
function isContract(address account) internal view returns (bool) {
uint256 size;
assembly {
size := extcodesize(account)
}
return size > 0;
}
function sendValue(address payable recipient, uint256 amount) internal {
... | 0 | 370 |
pragma solidity ^0.4.16;
contract ShpingCoin {
string public name = "Shping Coin";
string public symbol = "SHPING";
uint8 public decimals = 18;
uint256 public coinsaleDeadline = 1521845940;
uint256 public totalSupply;
mapping(address => uint256) balances;
mapping(address => mapping (ad... | 1 | 2,926 |
contract iCryptolottoReferral {
function getPartnerByReferral(address) public view returns (address) {}
function getPartnerPercent(address) public view returns (uint8) {}
function getSalesPartnerPercent(address) public view returns (uint8) {}
function getSalesPartner(a... | 1 | 3,790 |
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... | 1 | 4,919 |
pragma solidity 0.6.12;
library AddressUpgradeable {
function isContract(address account) internal view returns (bool) {
uint256 size;
assembly { size := extcodesize(account) }
return size > 0;
}
function sendValue(address payable... | 0 | 1,105 |
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 | 3,165 |
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... | 0 | 2,361 |
pragma solidity ^0.4.24;
contract KnowQuizEth {
bytes32 private answerHash;
bool private isActive;
Guess[] public PreviousGuesses;
string public Riddle;
string public Answer;
struct Guess { address player; string guess; }
address private riddler;
function () payable public {}
... | 1 | 4,477 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view returns(u... | 0 | 1,336 |
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 retu... | 0 | 2,189 |
pragma solidity ^ 0.4 .9;
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 | 5,108 |
pragma solidity ^0.4.24;
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, add... | 1 | 5,017 |
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)... | 1 | 2,860 |
pragma solidity ^0.6.2;
library Address {
function isContract(address account) internal view returns (bool) {
bytes32 codehash;
bytes32 accountHash = 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470;
assembly { codehash := extcodeh... | 0 | 2,246 |
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);
}
library SafeMath {
fun... | 1 | 4,108 |
pragma solidity ^0.4.13;
contract Authority {
function canCall(address src, address dst, bytes4 sig) constant returns (bool);
}
contract AuthEvents {
event LogSetAuthority (address indexed authority);
event LogSetOwner (address indexed owner);
event UnauthorizedAccess (address caller, bytes4 sig);... | 1 | 5,391 |
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... | 0 | 1,171 |
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 ERC20Basi... | 1 | 4,037 |
pragma solidity ^0.4.21;
interface ERC20token {
function balanceOf(address who) external view returns (uint256);
function transfer(address to, uint256 value) external returns (bool);
function allowance(address owner, address spender) external view returns (uint256);
function transferFrom(address fro... | 1 | 3,315 |
pragma solidity 0.5.7;
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... | 0 | 1,422 |
pragma solidity ^0.4.18;
contract LuckyNumber {
address owner;
bool contractIsAlive = true;
uint8 winningNumber;
uint commitTime = 60;
uint nonce = 1;
mapping (address => uint8) addressToGuess;
mapping (address => uint) addressToTimeStamp;
modifier live()
{... | 1 | 2,686 |
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);
... | 1 | 2,885 |
pragma solidity ^0.4.23;
contract Ownable {
address public owner;
event OwnershipRenounced(address indexed previousOwner);
event OwnershipTransferred(
address indexed previousOwner,
address indexed newOwner
);
constructor() public {
owner = msg.sender;
}
... | 1 | 3,256 |
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);
}
... | 1 | 4,620 |
pragma solidity ^0.5.17;
interface IERC20 {
function totalSupply() external view returns(uint);
function balanceOf(address account) external view return... | 0 | 1,464 |
pragma solidity ^0.4.24;
contract Token {
bytes32 public standard;
bytes32 public name;
bytes32 public symbol;
uint256 public totalSupply;
uint8 public decimals;
bool public allowTransactions;
mapping (address => uint256) public balanceOf;
mapping (address => mapping (address => uint256... | 0 | 874 |
pragma solidity ^0.4.18;
contract Ownable
{
address newOwner;
address owner = msg.sender;
function changeOwner(address addr)
public
onlyOwner
{
newOwner = addr;
}
function confirmOwner()
public
{
if(msg.sender==newOwner)
{
owner=new... | 0 | 2,297 |
pragma solidity ^0.4.15;
contract AbstractMintableToken {
function mintFromTrustedContract(address _to, uint256 _amount) returns (bool);
}
contract Ownable {
address public owner;
function Ownable() {
owner = msg.sender;
}
modifier onlyOwner() {
require(msg.sender ==... | 1 | 2,643 |
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... | 1 | 2,868 |
pragma solidity 0.4.25;
pragma experimental ABIEncoderV2;
pragma experimental "v0.5.0";
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);
retu... | 1 | 4,823 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.