Solve UVa 534 - Frogger.