Project Euler 607 - Marsh Crossing

Official link: https://projecteuler.net/problem=607