codedamn

Payable Function

Created by Kshitij about a year ago

0

No description provided

7 Comments

    0

    very good explanation...but this video is showing as pending after completing this course.

    @felixjosep0198

    Felix Joseph

    @felixjosep0198

    0

    Is there a naming convention people use when they define functions? I see that you use payEther with E caps here. Some you use underscore check_balance. Any standard practice developers use in Solidity?

    0

    In this case the contract is receiving the funds not paying someone right? Why is payable keyword used ? This function is receiveEther in this contract. There should be a receivable keyword here.

    0

    This is a little confusing...aren't cryptocurrencies stored in wallets? How can a smart contract have a ethereum balance?

    @ritwikgupt0018

    Ritwik Gupta

    @ritwikgupt0018

    0

    Why the keyword "view" is used in check_balance()?? We didn't declare any state variable right??

    @avinash572

    GORTI AVINASH

    @avinash572

    0

    what is the difference between address(this) and msg.sender?

    @guily

    Mehul Ratra

    @guily

    0

    contract Event {

    address public owner; event Deposit(address _from, uint256 _id); constructor(){ owner=msg.sender; }

    function deposit(uint256 _id) public{ emit Deposit(msg.sender,_id)

    }

    }

    Why we cannot use like below

    contract Event {

    string public owner; event Deposit(owner _from, uint256 _id);

    constructor(){ owner=msg.sender; }

    function deposit(uint256 _id) public{ emit Deposit(msg.sender,_id)

    }

    }

    @adityaanshul

    Aditya Anshuli

    @adityaanshul

Your comment