block by mimno d6b34ad78b8038de05c7073c76aa438c

Monte Carlo sampling for 538 riddler (pizza slices)

Full Screen

A Monte Carlo approximation of the area of overlap between two circles, inspired by this 538 riddler question. Sample random points in a rectangle and see which circle(s) they fall into. If “both” is more than half of “left” or “right”, chooose the middle slices.

index.html