THe contract calculates fee and prizePool seperately using their percentages. This causes small loss of wei as the contracts does not support decimals
uint256 prizePool = (totalAmountCollected * 80) / 100;
uint256 fee = (totalAmountCollected * 20) / 100;
Smart Contracts does not have decimals. so when getting a percentage of values, there are decimal losses. Calculating the fee as 20% of the totalCollected will cause these lost decimals to be stuck in the contract.
calculate fee as totalAmountCollected - prizePool to keep all the wei
like 1 wei
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.