How would i work out "x is what percent of y" or for example 5 is what percent 10 = 50%. For some reason i just cant wrap my head around it.
A clip of my code is below, i want to work out balanceOf[msg.sender] is what percent of totalCrowdFund.
uint256 public totalCrowdFund;
bool refundStatus;
mapping(address => uint256) public balanceOf;
mapping(address => bool) public emergencyRefundStatus;
constructor() {
owner = msg.sender;
totalCrowdFund = 0;
}