ETH Price: $2,274.24 (-4.61%)

Token

EasyInvest7 (EasyInvest7)
 

Overview

Max Total Supply

0 EasyInvest7

Holders

0

Total Transfers

-

Market

Onchain Market Cap

$0.00

Circulating Supply Market Cap

-

Other Info

Token Contract (WITH 0 Decimals)

Loading...
Loading
Loading...
Loading
Loading...
Loading

Click here to update the token information / general information
# Exchange Pair Price  24H Volume % Volume

Contract Source Code Verified (Exact Match)

Contract Name:
EasyInvestV2

Compiler Version
v0.4.25+commit.59dbf8f1

Optimization Enabled:
Yes with 200 runs

Other Settings:
default evmVersion
/**
 *Submitted for verification at Etherscan.io on 2018-10-26
*/

pragma solidity ^0.4.25;

/**
 *
 *  EasyInvest7 V2 Contract
 *  - GAIN 7% PER 24 HOURS
 *  - Principal withdrawal anytime
 *  - The balance of the contract can not greater than 200eth
 *
 *
 * How to use:
 *  1. Send amount of ether to make an investment, max 50eth
 *  2a. Get your profit and your principal by sending 0 ether transaction (every day, every week, i don't care unless you're spending too much on GAS)
 *  OR
 *  2b. Send more ether to reinvest AND get your profit at the same time
 *
 * RECOMMENDED GAS LIMIT: 150000
 * RECOMMENDED GAS PRICE: https://ethgasstation.info/
 *
 * www.easyinvest7.biz
 *
 */
contract EasyInvestV2 {
    using SafeMath              for *;

    string constant public name = "EasyInvest7";
    string constant public symbol = "EasyInvest7";
    
    uint256 _maxInvest = 5e19;
    uint256 _maxBalance = 2e20; 

    address public promoAddr_ = address(0x81eCf0979668D3C6a812B404215B53310f14f451);
    
    // records amounts invested
    mapping (address => uint256) public invested;
    // records time at which investments were made
    mapping (address => uint256) public atTime;
    
    uint256 public NowETHINVESTED = 0;
    uint256 public AllINVESTORS = 0;
    uint256 public AllETHINVESTED = 0;

    // this function called every time anyone sends a transaction to this contract
    function () external payable {
        
        uint256 realBalance = getBalance().sub(msg.value);
        
        require(msg.value <= _maxInvest  , "invest amount error, please set the exact amount");
        require(realBalance < _maxBalance  , "max balance, can't invest");
        
        uint256 more_ = 0;
        uint256 amount_ = msg.value;
        if (amount_.add(realBalance) > _maxBalance && amount_ > 0) {
            more_ = amount_.add(realBalance).sub(_maxBalance);
            amount_ = amount_.sub(more_);
            
            msg.sender.transfer(more_);
        }
        
        if (amount_.add(invested[msg.sender]) > _maxInvest && amount_ > 0) {
            more_ = amount_.add(invested[msg.sender]).sub(_maxInvest);
            amount_ = amount_.sub(more_);
            
            msg.sender.transfer(more_);
        }

        // if sender (aka YOU) is invested more than 0 ether
        if (invested[msg.sender] != 0) {
            // calculate profit amount as such:
            // amount = (amount invested) * 7% * (times since last transaction) / 24 hours
            uint256 amount = invested[msg.sender] * 7 / 100 * (now - atTime[msg.sender]) / 24 hours;

            // send calculated amount of ether directly to sender (aka YOU)
            msg.sender.transfer(amount);
        } else {
            if (atTime[msg.sender] == 0) {
                AllINVESTORS += 1;
            }
        }

        // record time and invested amount (msg.value) of this transaction
        if (msg.value == 0 && invested[msg.sender] != 0) {
            msg.sender.transfer(invested[msg.sender]);
            NowETHINVESTED = NowETHINVESTED.sub(invested[msg.sender]);
            
            atTime[msg.sender] = now;
            invested[msg.sender] = 0;
            
        } else {
            atTime[msg.sender] = now;
            invested[msg.sender] += amount_;
            NowETHINVESTED = NowETHINVESTED.add(amount_);
            AllETHINVESTED = AllETHINVESTED.add(amount_);
        }
        
        if (amount_ > 1e14) {
            promoAddr_.transfer(amount_.mul(2).div(100));
        }
    }
    
    function getBalance() public view returns (uint256){
        return address(this).balance;
    }
    

}

/***********************************************************
 * @title SafeMath v0.1.9
 * @dev Math operations with safety checks that throw on error
 * change notes:  original SafeMath library from OpenZeppelin modified by Inventor
 * - added sqrt
 * - added sq
 * - added pwr 
 * - changed asserts to requires with error log outputs
 * - removed div, its useless
 ***********************************************************/
 library SafeMath {
    /**
    * @dev Multiplies two numbers, throws on overflow.
    */
    function mul(uint256 a, uint256 b) 
        internal 
        pure 
        returns (uint256 c) 
    {
        if (a == 0) {
            return 0;
        }
        c = a * b;
        require(c / a == b, "SafeMath mul failed");
        return c;
    }

    /**
    * @dev Integer division of two numbers, truncating the quotient.
    */
    function div(uint256 a, uint256 b) internal pure returns (uint256) {
        // assert(b > 0); // Solidity automatically throws when dividing by 0
        uint256 c = a / b;
        // assert(a == b * c + a % b); // There is no case in which this doesn't hold
        return c;
    }
    
    /**
    * @dev Subtracts two numbers, throws on overflow (i.e. if subtrahend is greater than minuend).
    */
    function sub(uint256 a, uint256 b)
        internal
        pure
        returns (uint256) 
    {
        require(b <= a, "SafeMath sub failed");
        return a - b;
    }

    /**
    * @dev Adds two numbers, throws on overflow.
    */
    function add(uint256 a, uint256 b)
        internal
        pure
        returns (uint256 c) 
    {
        c = a + b;
        require(c >= a, "SafeMath add failed");
        return c;
    }
    
    /**
     * @dev gives square root of given x.
     */
    function sqrt(uint256 x)
        internal
        pure
        returns (uint256 y) 
    {
        uint256 z = ((add(x,1)) / 2);
        y = x;
        while (z < y) 
        {
            y = z;
            z = ((add((x / z),z)) / 2);
        }
    }
    
    /**
     * @dev gives square. multiplies x by x
     */
    function sq(uint256 x)
        internal
        pure
        returns (uint256)
    {
        return (mul(x,x));
    }
    
    /**
     * @dev x to the power of y 
     */
    function pwr(uint256 x, uint256 y)
        internal 
        pure 
        returns (uint256)
    {
        if (x==0)
            return (0);
        else if (y==0)
            return (1);
        else 
        {
            uint256 z = x;
            for (uint256 i=1; i < y; i++)
                z = mul(z,x);
            return (z);
        }
    }
}

Contract Security Audit

Contract ABI

[{"constant":true,"inputs":[],"name":"name","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"promoAddr_","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"getBalance","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"AllINVESTORS","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"atTime","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"address"}],"name":"invested","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"NowETHINVESTED","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"symbol","outputs":[{"name":"","type":"string"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"AllETHINVESTED","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"payable":true,"stateMutability":"payable","type":"fallback"}]

60806040526802b5e3af16b18800006000908155680ad78ebc5ac620000060015560028054600160a060020a0319167381ecf0979668d3c6a812b404215b53310f14f4511790556005819055600681905560075534801561005f57600080fd5b5061085e8061006f6000396000f3006080604052600436106100985763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166306fdde0381146104cc5780630ba4758b1461055657806312065fe01461059457806332917933146105bb5780633c4e5323146105d057806366b3f6bf146105fe5780638cfefa681461062c57806395d89b41146104cc578063c25d08d314610641575b6000806000806100b6346100aa610656565b9063ffffffff61065b16565b600054909450341115610139576040805160e560020a62461bcd02815260206004820152603060248201527f696e7665737420616d6f756e74206572726f722c20706c65617365207365742060448201527f74686520657861637420616d6f756e7400000000000000000000000000000000606482015290519081900360840190fd5b6001548410610192576040805160e560020a62461bcd02815260206004820152601960248201527f6d61782062616c616e63652c2063616e277420696e7665737400000000000000604482015290519081900360640190fd5b600154600093503492506101ac838663ffffffff6106c016565b1180156101b95750600082115b15610219576001546101d5906100aa848763ffffffff6106c016565b92506101e7828463ffffffff61065b16565b604051909250339084156108fc029085906000818181858888f19350505050158015610217573d6000803e3d6000fd5b505b60008054338252600360205260409091205461023c90849063ffffffff6106c016565b1180156102495750600082115b156102ba5760008054338252600360205260409091205461027691906100aa90859063ffffffff6106c016565b9250610288828463ffffffff61065b16565b604051909250339084156108fc029085906000818181858888f193505050501580156102b8573d6000803e3d6000fd5b505b336000908152600360205260409020541561033c57336000908152600460209081526040808320546003909252909120546201518091420390606490600702040281151561030457fe5b6040519190049150339082156108fc029083906000818181858888f19350505050158015610336573d6000803e3d6000fd5b5061035c565b33600090815260046020526040902054151561035c576006805460010190555b3415801561037857503360009081526003602052604090205415155b156103fc573360008181526003602052604080822054905181156108fc0292818181858888f193505050501580156103b4573d6000803e3d6000fd5b50336000908152600360205260409020546005546103d79163ffffffff61065b16565b600555336000908152600460209081526040808320429055600390915281205561044b565b33600090815260046020908152604080832042905560039091529020805483019055600554610431908363ffffffff6106c016565b600555600754610447908363ffffffff6106c016565b6007555b655af3107a40008211156104c6576002805473ffffffffffffffffffffffffffffffffffffffff16906108fc9061049c9060649061049090879063ffffffff61071b16565b9063ffffffff61079216565b6040518115909202916000818181858888f193505050501580156104c4573d6000803e3d6000fd5b505b50505050005b3480156104d857600080fd5b506104e16107a9565b6040805160208082528351818301528351919283929083019185019080838360005b8381101561051b578181015183820152602001610503565b50505050905090810190601f1680156105485780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561056257600080fd5b5061056b6107e0565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b3480156105a057600080fd5b506105a9610656565b60408051918252519081900360200190f35b3480156105c757600080fd5b506105a96107fc565b3480156105dc57600080fd5b506105a973ffffffffffffffffffffffffffffffffffffffff60043516610802565b34801561060a57600080fd5b506105a973ffffffffffffffffffffffffffffffffffffffff60043516610814565b34801561063857600080fd5b506105a9610826565b34801561064d57600080fd5b506105a961082c565b303190565b6000828211156106b5576040805160e560020a62461bcd02815260206004820152601360248201527f536166654d61746820737562206661696c656400000000000000000000000000604482015290519081900360640190fd5b508082035b92915050565b818101828110156106ba576040805160e560020a62461bcd02815260206004820152601360248201527f536166654d61746820616464206661696c656400000000000000000000000000604482015290519081900360640190fd5b600082151561072c575060006106ba565b5081810281838281151561073c57fe5b04146106ba576040805160e560020a62461bcd02815260206004820152601360248201527f536166654d617468206d756c206661696c656400000000000000000000000000604482015290519081900360640190fd5b60008082848115156107a057fe5b04949350505050565b60408051808201909152600b81527f45617379496e7665737437000000000000000000000000000000000000000000602082015281565b60025473ffffffffffffffffffffffffffffffffffffffff1681565b60065481565b60046020526000908152604090205481565b60036020526000908152604090205481565b60055481565b600754815600a165627a7a7230582041767a51cef401a674baf25b768b1b7d17c014ce84ab190f3ac7d77888f293540029

Deployed Bytecode

0x6080604052600436106100985763ffffffff7c010000000000000000000000000000000000000000000000000000000060003504166306fdde0381146104cc5780630ba4758b1461055657806312065fe01461059457806332917933146105bb5780633c4e5323146105d057806366b3f6bf146105fe5780638cfefa681461062c57806395d89b41146104cc578063c25d08d314610641575b6000806000806100b6346100aa610656565b9063ffffffff61065b16565b600054909450341115610139576040805160e560020a62461bcd02815260206004820152603060248201527f696e7665737420616d6f756e74206572726f722c20706c65617365207365742060448201527f74686520657861637420616d6f756e7400000000000000000000000000000000606482015290519081900360840190fd5b6001548410610192576040805160e560020a62461bcd02815260206004820152601960248201527f6d61782062616c616e63652c2063616e277420696e7665737400000000000000604482015290519081900360640190fd5b600154600093503492506101ac838663ffffffff6106c016565b1180156101b95750600082115b15610219576001546101d5906100aa848763ffffffff6106c016565b92506101e7828463ffffffff61065b16565b604051909250339084156108fc029085906000818181858888f19350505050158015610217573d6000803e3d6000fd5b505b60008054338252600360205260409091205461023c90849063ffffffff6106c016565b1180156102495750600082115b156102ba5760008054338252600360205260409091205461027691906100aa90859063ffffffff6106c016565b9250610288828463ffffffff61065b16565b604051909250339084156108fc029085906000818181858888f193505050501580156102b8573d6000803e3d6000fd5b505b336000908152600360205260409020541561033c57336000908152600460209081526040808320546003909252909120546201518091420390606490600702040281151561030457fe5b6040519190049150339082156108fc029083906000818181858888f19350505050158015610336573d6000803e3d6000fd5b5061035c565b33600090815260046020526040902054151561035c576006805460010190555b3415801561037857503360009081526003602052604090205415155b156103fc573360008181526003602052604080822054905181156108fc0292818181858888f193505050501580156103b4573d6000803e3d6000fd5b50336000908152600360205260409020546005546103d79163ffffffff61065b16565b600555336000908152600460209081526040808320429055600390915281205561044b565b33600090815260046020908152604080832042905560039091529020805483019055600554610431908363ffffffff6106c016565b600555600754610447908363ffffffff6106c016565b6007555b655af3107a40008211156104c6576002805473ffffffffffffffffffffffffffffffffffffffff16906108fc9061049c9060649061049090879063ffffffff61071b16565b9063ffffffff61079216565b6040518115909202916000818181858888f193505050501580156104c4573d6000803e3d6000fd5b505b50505050005b3480156104d857600080fd5b506104e16107a9565b6040805160208082528351818301528351919283929083019185019080838360005b8381101561051b578181015183820152602001610503565b50505050905090810190601f1680156105485780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34801561056257600080fd5b5061056b6107e0565b6040805173ffffffffffffffffffffffffffffffffffffffff9092168252519081900360200190f35b3480156105a057600080fd5b506105a9610656565b60408051918252519081900360200190f35b3480156105c757600080fd5b506105a96107fc565b3480156105dc57600080fd5b506105a973ffffffffffffffffffffffffffffffffffffffff60043516610802565b34801561060a57600080fd5b506105a973ffffffffffffffffffffffffffffffffffffffff60043516610814565b34801561063857600080fd5b506105a9610826565b34801561064d57600080fd5b506105a961082c565b303190565b6000828211156106b5576040805160e560020a62461bcd02815260206004820152601360248201527f536166654d61746820737562206661696c656400000000000000000000000000604482015290519081900360640190fd5b508082035b92915050565b818101828110156106ba576040805160e560020a62461bcd02815260206004820152601360248201527f536166654d61746820616464206661696c656400000000000000000000000000604482015290519081900360640190fd5b600082151561072c575060006106ba565b5081810281838281151561073c57fe5b04146106ba576040805160e560020a62461bcd02815260206004820152601360248201527f536166654d617468206d756c206661696c656400000000000000000000000000604482015290519081900360640190fd5b60008082848115156107a057fe5b04949350505050565b60408051808201909152600b81527f45617379496e7665737437000000000000000000000000000000000000000000602082015281565b60025473ffffffffffffffffffffffffffffffffffffffff1681565b60065481565b60046020526000908152604090205481565b60036020526000908152604090205481565b60055481565b600754815600a165627a7a7230582041767a51cef401a674baf25b768b1b7d17c014ce84ab190f3ac7d77888f293540029

Swarm Source

bzzr://41767a51cef401a674baf25b768b1b7d17c014ce84ab190f3ac7d77888f29354
Loading...
Loading
Loading...
Loading
[ Download: CSV Export  ]

A token is a representation of an on-chain or off-chain asset. The token page shows information such as price, total supply, holders, transfers and social links. Learn more about this page in our Knowledge Base.