Skip to content
Vamshi Jandhyala

Mathematics

Well Well Well

A Jane Street puzzle: a 7×7 well with per-cell depths 1 through 49 is filled at 1 cubic foot per minute from the cell marked 1; water disperses evenly among adjacent lower-depth regions. After how many minutes does the water level in cell 43 start to rise?

Download PDF →


NetworkX + exact rational arithmetic (Fraction) models the water distribution. Water entering a flat region disperses among its deepest neighbours equally; when a region has no deeper neighbour, it fills until its depth matches the next. Simulation yields 360 minutes. Full code and the final depth grid are in the PDF.


More mathematical writing →