-
-
Save Ultra-Tech-code/d1a68029e191b38d7f40680419a9c53b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//SPDX-License-Identifier: MIT | |
pragma solidity ^0.8.13; | |
contract fundContract{ | |
mapping(address => uint) balances; | |
function deposit() public payable{ | |
require(msg.value > 1, "Your deposit must be greater than 1 eth"); | |
balances[msg.sender] += msg.value; | |
} | |
function getBalance() public view returns(uint){ | |
return balances[msg.sender]; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment