I visited a geocache once that required solving this same exact problem.

Cheers