Writing payout logic in Foundry
The betting contract got interesting once the payout math had to line up with actual tests. Foundry was useful here because it made the state changes and emitted values easy to pin down.

The betting contract got interesting once the payout math had to line up with actual tests. Foundry was useful here because it made the state changes and emitted values easy to pin down.